This is the mail archive of the fortran@gcc.gnu.org mailing list for the GNU Fortran project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: stopping gdb at runtime errors.



Hi Niels,


Niels L. Ellegaard wrote:
I am using gfortran with gdb, and I would like to set a single break
point that stoppped the program just before it crashed due to any
runtime error. That would allow me a last view at my variables before
a any crash.

I would also like to set a single breakpoint ("break STOP" ??) that
stopped the program whenever the fortran statement named "STOP" were
about to be executed.

The relevant symbols are __gfortran_stop_numeric, __gfortran_stop_string for STOP and __gfortran_runtime_error for runtime errors. It should be possible to set breakpoints on them, though I haven't tried.


Cheers,
- Tobi


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]