This is the mail archive of the mailing list for the GCC 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]

[Bug libfortran/29649] Force core dump on runtime library errors

------- Comment #6 from burnus at gcc dot gnu dot org  2006-10-31 18:37 -------
> Using unwind is the way to go for a more serious solution.
Looks nice as a starting point. (My biggest problem with developing this would
be to find out whether it works on strange machines like Sparc, Windows etc.)

> It's how java does it, for example (with addr2line to get file
> and line information).

[to spare others the searching] addr2line is part of binutils. Using binutils'
libbfd, resolving the symbols could be resolved compareably easily. (At least
it looks like this, glancing at binutils/addr2line.c).

Thus, in total I think I would like to have the following in gfortran:

- Support for coredumps (compile time? Environment variable? The latter
overwriting the former?)
[Advantage compile-time option: The core is there, if one needs it. Advantage
run-time option: One can quickly turn it on, if needed.]

- Traceback support more or less as outlined above (comment 4, comment 3),
which prints only the Hex address (similar to the unwind.diff, attachment
12519) or the backtrace_symbols() example in comment 3). One should mention the
addr2line program in the manpage/manual.

- Optionally, linking with libbfd and providing symbol-resolved traceback.


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