review for 7055355: JSR 292: crash while throwing WrongMethodTypeException

Tom Rodriguez tom.rodriguez at
Thu Jun 16 09:58:27 PDT 2011

On Jun 16, 2011, at 2:47 AM, Christian Thalinger wrote:

> On Jun 16, 2011, at 7:32 AM, Tom Rodriguez wrote:
>> 174 lines changed: 54 ins; 111 del; 9 mod; 30934 unchg
>> 7055355: JSR 292: crash while throwing WrongMethodTypeException
>> Reviewed-by:
>> When throwing a WrongMethodTypeException from a MethodHandle the
>> existing code was pretending it was in the interpreter which worked ok
>> most of the time but would sometimes die when trying to throw with a
>> compiled caller.  It could cause asserts in some contexts or result in
>> GC crashes.  The fix is to remove the old machinery in favor of the
>> more standard code for throwing exceptions in
>> StubRoutines/SharedRuntime.  There was one other use of the old throw
>> machinery but it's in part of check that can never fail since we won't
>> enable method handles unless we have a non-NULL rasie exception
>> method.  There's an extra fix in the there to reject lookups of
>> clinit.  It isn't critical but it allows all the JCK tests to run
>> without asserting.  Tested with failing JCK test and jruby crasher on
>> sparc/x86 with client/server/d64, along with a full run of the
>> invokedynamic JCK tests, the JLI regression tests and the vm.mlvm
>> tests.
> You didn't remove the NULL-checking code of the raise_exception method in methodHandles_sparc.cpp.  Otherwise this looks good.

Thanks.  I felt like I hadn't deleted enough copies but grep didn't find the old throw routine anymore so I thought I was done.  I've deleted it now.


> -- Christian

More information about the hotspot-compiler-dev mailing list