RFR (S): JDK-8051045: HotSpot fails to wrap Exceptions from invokedynamic in a BootstrapMethodError
Andreas Eriksson
andreas.eriksson at oracle.com
Thu May 7 11:27:34 UTC 2015
Thanks David!
On 2015-05-07 13:23, David Simms wrote:
>
> Looks good Andreas
>
> /David
>
>
> On 7/05/2015 1:20 p.m., Andreas Eriksson wrote:
>> Thanks Coleen!
>>
>> Could I have another review as well please?
>>
>> - Andreas
>>
>> On 2015-05-06 19:09, Coleen Phillimore wrote:
>>>
>>> This change looks good.
>>> Coleen
>>>
>>> On 5/6/15, 6:37 AM, Andreas Eriksson wrote:
>>>> Hi, anyone who can take a look at this review?
>>>>
>>>> http://cr.openjdk.java.net/~aeriksso/8051045/webrev.00/
>>>> https://bugs.openjdk.java.net/browse/JDK-8051045
>>>>
>>>> - Andreas
>>>>
>>>> On 2015-04-29 13:36, Andreas Eriksson wrote:
>>>>> Hi,
>>>>>
>>>>> Please review this change to resolve_invokedynamic.
>>>>>
>>>>> In linkResolver.cpp LinkResolver::resolve_invokedynamic could miss
>>>>> wrapping some exceptions in BootstrapMethodError.
>>>>> According to the JVM specification [1] invokedynamic should wrap
>>>>> any exceptions that occur during resolution in a
>>>>> BootstrapMethodError.
>>>>> As part of other changes, exception CHECK macros where used, which
>>>>> do not wrap the exception as needed.
>>>>>
>>>>> This fix moves the exception wrapping logic to a separate
>>>>> function, wrap_invokedynamic_exception.
>>>>> It then changes the functions that can throw exceptions to not use
>>>>> the CHECK macro.
>>>>> Instead the exception wrapping function is called immediately
>>>>> after functions that can throw.
>>>>>
>>>>> Included in the change is a test that tries to access a private
>>>>> method with invokedynamic.
>>>>> The test expects a BootstrapMethodError, but without the fix it
>>>>> gets an IllegalAccessError and the test fails.
>>>>>
>>>>> Webrev: http://cr.openjdk.java.net/~aeriksso/8051045/webrev.00/
>>>>>
>>>>> Thanks,
>>>>> Andreas
>>>>>
>>>>> [1]
>>>>> http://docs.oracle.com/javase/specs/jvms/se8/html/jvms-6.html#jvms-6.5.invokedynamic
>>>>
>>>
>>
>
More information about the hotspot-runtime-dev
mailing list