[11] RFR(S): 8148871: Possible wrong expression stack depth at deopt point

Tobias Hartmann tobias.hartmann at oracle.com
Thu Mar 1 06:35:39 UTC 2018


Thanks Tom.

Best regards,
Tobias

On 28.02.2018 19:21, Tom Rodriguez wrote:
> Looks good.  Thanks for diagnosing this.
> 
> tom
> 
> Tobias Hartmann wrote:
>> Hi,
>>
>> please review the following patch:
>> https://bugs.openjdk.java.net/browse/JDK-8148871
>> http://cr.openjdk.java.net/~thartmann/8148871/webrev.00/
>>
>> The problem is that the stack verification code uses the interpreter oop map to get the stack size
>> of the next instruction. However, for calls, the oop map contains the state *after* the instruction.
>> With next_mask_expression_stack_size = 0, the result of 'next_mask_expression_stack_size -
>> top_frame_expression_stack_adjustment' is negative and verification fails. For details, see my
>> comment in the bug [1].
>>
>> The fix is to add a special case for invoke bytecodes and use the parameter size instead of the oop
>> map in that case. Tested with hs-tier1/2 with -XX:+VerifyStack (I hit 8198826 which I'll fix with
>> another patch).
>>
>> Thanks,
>> Tobias
>>
>> [1]
>> https://bugs.openjdk.java.net/browse/JDK-8148871?focusedCommentId=14160003&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-14160003
>>


More information about the hotspot-dev mailing list