I don't know of any such switch.
In my experience, ddd does that quite sasisfactory without running much slower, just at the speed of normal debug code.
Just do Status > Backtrace
in DDD after the crash, if it does not position you automatically to the line after the crash.
In some complicated cases, valgrind also helps pinpoint the error, as the error may be caused by trashing of memory prior to actual core dump. This indeed runs many times slower.
Same way as you would with any other compiler. Compile your program with switch
and then run it with ddd by
Intel compiler also comes wiht idb, which can be used in the same way.
I perfer ddd, since it can nicely graphically display the data structures.