JDK-8330105 : SharedRuntime::resolve* should respect interpreter-only mode
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 23
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2024-04-11
  • Updated: 2024-06-10
  • Resolved: 2024-04-15
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 23
23 b19Fixed
Related Reports
Relates :  
Relates :  
Description
JavaThread::set_interp_only_mode may be called while a thread is blocked waiting for a JIT compilation to complete. This happens often with -Xcomp. The VM will enter the compiled code once the compilation finishes. As a consequence, the assumption for interp_only_mode does not hold, i.e., the VM will still dispatch to compiled code for threads that are in interp_only_mode. Assertions based on this assumption will fail. For example, vmTestbase/nsk/jdi tests fail on libgraal at this assertion: https://github.com/openjdk/jdk/blob/8817ba450c0eac6f7c1ff19b16c11a26ff2ed109/src/hotspot/share/prims/jvmtiThreadState.cpp#L867 

To reproduce, use the following command:

make test TEST_VM_OPTS="-Xcomp -XX:-TieredCompilation -XX:+UnlockExperimentalVMOptions -XX:+UseJVMCICompiler" TEST=vmTestbase/nsk/jdi/VirtualMachine/setDefaultStratum/setDefaultStratum003/setDefaultStratum003.java  JDK_UNDER_TEST=/path/to/libgraal_build
Comments
Changeset: 5404b4ea Author: Yudi Zheng <yzheng@openjdk.org> Committer: Doug Simon <dnsimon@openjdk.org> Date: 2024-04-15 08:07:49 +0000 URL: https://git.openjdk.org/jdk/commit/5404b4eafc2eb3291cecf99f98728946388f5d16
15-04-2024

A pull request was submitted for review. URL: https://git.openjdk.org/jdk/pull/18741 Date: 2024-04-11 13:50:25 +0000
12-04-2024

ILW = Same as JDK-8218403 = P3
12-04-2024