This is the mail archive of the java-discuss@sourceware.cygnus.com mailing list for the Java project.


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

Debugging unhandled exceptions


When running Java code that generates an unhandled exception in a Java VM, the
VM prints a very convenient stack trace showing where the exception occured.
When the same thing happens in libgcj, only the type of the exception gets
printed, and you need to use gdb to try to get a backtrace and work out where
the exception occured. Unfortunatly, libgcj aborting on an unhandled exception
is considered by gdb to be normal exit condition, and this makes it rather
difficult to find the point in the program that actually generated the
exception. It would be really cool if libgcj could somehow signal gdb so that it
would stop at the location of the exception and allow you to get a useful
backtrace, in the same way that gdb will stop on unhandled signals in C code.

Any ideas on how easy/difficult this would be to implement?

regards

  [ bryce ]



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