Request for reviews (XL): 6919934: JSR 292 needs to support x86 C1
Tom Rodriguez
tom.rodriguez at oracle.com
Mon Mar 29 11:28:12 PDT 2010
On Mar 29, 2010, at 5:46 AM, Christian Thalinger wrote:
> On Wed, 2010-03-24 at 13:57 -0700, Christian Wimmer wrote:
>> Hi Christian, Tom,
>>
>> This changeset modifies the GraphBuilder such that now every method
>> has a synthetic exception handler that covers the whole method.
>> Previously, it was only necessary for synchronized methods (and with
>> dtrace). I added the relevant diff below - note that the "if" is
>> remoed by the patch.
>> I think this affects the speed of C1 negatively, and perhaps also the
>> generated code (it might slow down the exception dispatch). Why is
>> this change necessary?
>
> Tom would know better as he did the changes, but we changed the code so
> that C1 has the same unwinding mechanism as C2 does. This makes the C1
> code a bit simpler.
Otherwise the unwind code has to do a call into the runtime to find out the nmethod frame_size so that it can take the frame off the stack properly. I just didn't like doing that and never liked that C1 and C2 did these differently for no good reason so it seemed easiest to make it work the same.
>
> Regarding performance, why do you think it affects performance
> negatively?
I don't see any reason that this should hurt performance, at least enough to matter. The unwind path is changed to a jump to a tiny trampoline in the nmethod that adjusts sp and jumps to the unwind handler, so you don't go directly to the unwind handler but it's pretty minimal. Are there are other code generation effects that would be expected?
tom
>
> -- Christian
>
More information about the hotspot-compiler-dev
mailing list