This is the mail archive of the
java-patches@sourceware.cygnus.com
mailing list for the Java project.
Re: Patch: -fasynchronous-exceptions
- To: tromey at cygnus dot com
- Subject: Re: Patch: -fasynchronous-exceptions
- From: Andrew Haley <aph at pasanda dot cygnus dot co dot uk>
- Date: 27 Apr 2000 09:00:41 -0000
- CC: java-patches at sourceware dot cygnus dot com
> From: Tom Tromey <tromey@cygnus.com>
> Date: 26 Apr 2000 11:32:46 -0600
>
> Andrew notes that gcc's exception handling in leaf functions is
> currently broken, but that using -fasynchronous-exceptions works
> around it. So, I'm committing this patch.
This obviously has a negative effect on code size, but the alternative
is far worse. What has happened is that the gcc maintainers has made
leaf functions not emit exception tables at all, because (obviously)
they don't call any functions and therefore can't raise exceptions.
This isn't true for us Java users, becaue SEGV and FP signals can do
so.
I have a plan for a patch that will fix this forever. It's like
asynchronous-exceptions, but limited to the cases we actually need,
which are divide instructions and pointer accesses. I'd like to make
a new insn predicate called something like CAN_SIGNAL that returns
true only for divides and (non-stack) pointer references. Given such
a predicate, we need only to generate unwinder information when really
necessary.
I don't have time to do this right now, but in my opinion it would be
a great improvement.
Andrew.