This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Preliminary patch: New stack trace infrastructure
- From: Andrew Haley <aph at redhat dot com>
- To: Bryce McKinlay <mckinlay at redhat dot com>
- Cc: Java Patches <java-patches at gcc dot gnu dot org>
- Date: Mon, 29 Nov 2004 17:18:08 +0000
- Subject: Preliminary patch: New stack trace infrastructure
- References: <41A6D134.9080908@redhat.com>
Bryce McKinlay writes:
> There is still some cleanup work to be done and missing pieces to be
> filled in (most noteably, AccessController), but here is a preliminary
> snapshot of the new stack trace infrastructure code.
>
> Basically, this code will give clean looking, accurate stack traces
> using the DWARF2 debugging information and gcj's compiled metadata.
>
> Key benefits:
>
> - It gives stack traces, complete with line numbers, through interpreted
> bytecode (part of this code is based on an earlier implementation from
> Mark Wielaard - thanks Mark!)
> - It gives stack traces through shared libraries. Currently, addr2line
> is still used to do this, which can be a noticeable performance problem
> when it has to open big libraries like libgcj, but I plan to integrate
> Casey Marshall's DWARF2 debug-info reading code soon. For now we may
> wish to disable addr2line usage for applications where printStackTrace()
> must be fast.
> - Stack trace implementation is secure: stack frame -> class association
> is no longer based on mangled names, so classes wont be able to
> illegally elevate their privileges just by being called the same name as
> a secure class.
> - Stack printing looks nicer and is smarter about which frames to
> include or exclude.
This looks good, and you submitted it before the Thanksgiving
deadline. However, we must not cause regressions for non-DWARF2
unwinding hosts. It looks like Windows users, in particular will be
stuck with sjlj unwinding for some time to come.
What happens to a Windows build when this patch is applied?
Andrew.