RFR: 8257917: [JVMCI] crash when materializing boxed values under -Xcomp

Doug Simon dnsimon at openjdk.java.net
Tue Dec 8 21:40:39 UTC 2020


The following crash can occur under `-Xcomp` when JVMCI compiled code tries to materialize a virtual box (e.g. `java.lang.Character` object):
# Internal Error (deoptimization.cpp:798), pid=26877, tid=8195
# guarantee(ik->is_initialized()) failed: java/lang/Character$CharacterCache must be initialized
The problem occurs when the caching class (`java/lang/Character$CharacterCache` in this case) has not been initialized. Normally, the caching class will be initialized when interpreting code that does autoboxing. However, with `-XX:-TieredCompilation -Xcomp` it's possible for class initialization to not be interpreted. When JVMCI compiled code containing virtual boxes is about to be installed, the VM must ensure the box caching classes are initialized. This PR does exactly that.

-------------

Commit messages:
 - ensure boxing cache classes are initialized when installing JVMCI compiled code

Changes: https://git.openjdk.java.net/jdk/pull/1705/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=1705&range=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8257917
  Stats: 57 lines in 4 files changed: 46 ins; 10 del; 1 mod
  Patch: https://git.openjdk.java.net/jdk/pull/1705.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/1705/head:pull/1705

PR: https://git.openjdk.java.net/jdk/pull/1705


More information about the hotspot-compiler-dev mailing list