JDK-8255233 : InterpreterRuntime::at_unwind should be a JRT_LEAF
  • Type: Bug
  • Component: hotspot
  • Sub-Component: gc
  • Affected Version: 16
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • Submitted: 2020-10-22
  • Updated: 2021-03-08
  • Resolved: 2020-10-28
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 16
16 b22Fixed
Related Reports
Relates :  
Relates :  
Description
InterpreterRuntime::at_unwind is called at the very beginning of remove_activation(), to notify concurrent stack processing that a frame is about to be unwound. It is currently a JRT_ENTRY, because it needs a last_Java_frame to see what frame is about to get unwound.

However, there are special return paths used by JVMTI pop frame, that checks if the caller frame is deoptimized, then calls a special path that removes the top activation, assuming that does not enter the deopt handler. The new JRT_ENTRY makes that reasoning invalid.

Therefore, we need this to be a JRT_LEAF, that sets a last Java frame, to make everyone happy.
Comments
Changeset: aaf4f690 Author: Erik ��sterlund <eosterlund@openjdk.org> Date: 2020-10-28 14:14:51 +0000 URL: https://git.openjdk.java.net/jdk/commit/aaf4f690
28-10-2020

This bug fails with a bad oop in a return statement, when running the following reproducer: while true; do make test JTREG="RETAIN=all" TEST=open/test/hotspot/jtreg/vmTestbase/nsk/jvmti/ForceEarlyReturn/ForceEarlyReturn002 TEST_OPTS_JAVA_OPTIONS="-XX:+UseZGC -Xmx2g -XX:ZCollectionInterval=0.0001 -XX:ZFragmentationLimit=0.01 -XX:+VerifyOops -XX:+ZVerifyViews" ; done It reproduces approximately 1/15 runs.
23-10-2020