Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8279437

[JVMCI] exception in HotSpotJVMCIRuntime.translate can exit the VM

XMLWordPrintable

    • b05

        The HotSpotJVMCIRuntime.translate method copies objects between the HotSpot heap and the libjvmci heap. Failure during copying (e.g. due to an OutOfMemoryError) currently results in a VM exit as shown below:

         testHostOOMResourceLimit: Uncaught exception exiting JVMCIEnv scope entered at open/src/hotspot/share/jvmci/jvmciCompilerToVM.cpp:2467
        java.lang.OutOfMemoryError: Java heap space
        at jdk.vm.ci.hotspot.CompilerToVM.getResolvedJavaType0(jdk.internal.vm.ci@17.0.2/Native Method)
        at jdk.vm.ci.hotspot.CompilerToVM.getResolvedJavaType(jdk.internal.vm.ci@17.0.2/CompilerToVM.java:675)
        at jdk.vm.ci.hotspot.HotSpotResolvedJavaMethodImpl.getHolder(jdk.internal.vm.ci@17.0.2/HotSpotResolvedJavaMethodImpl.java:97)
        at jdk.vm.ci.hotspot.HotSpotResolvedJavaMethodImpl.fromMetaspace(jdk.internal.vm.ci@17.0.2/HotSpotResolvedJavaMethodImpl.java:115)
        #
        # A fatal error has been detected by the Java Runtime Environment:
        #
        # Internal Error (jvmciRuntime.cpp:1587), pid=7044, tid=7057
        # fatal error: Fatal exception in JVMCI: Uncaught exception exiting JVMCIEnv scope entered at open/src/hotspot/share/jvmci/jvmciCompilerToVM.cpp:2467
        #
        # JRE version: Java(TM) SE Runtime Environment GraalVM LIBGRAAL_EE 22.0.0-dev (17.0.2+5) (build 17.0.2+5-LTS-jvmci-22.0-b02)
        # Java VM: Java HotSpot(TM) 64-Bit Server VM GraalVM LIBGRAAL_EE 22.0.0-dev (17.0.2+5-LTS-jvmci-22.0-b02, mixed mode, sharing, tiered, jvmci, jvmci compiler, compressed oops, compressed class ptrs, g1 gc, linux-amd64)
        # Problematic frame:
        # V [libjvm.so+0x98dc64] JVMCIRuntime::fatal_exception(JVMCIEnv*, char const*)+0x74
        #
        # No core dump will be written. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
        #
        # An error report file with more information is saved as:
        # /b/b/e/main/vm-enterprise/hs_err_pid7044.log
        #
        # If you would like to submit a bug report, please visit:
        # https://bugreport.java.com/bugreport/crash.jsp
        #

        Instead, the exception should be propagated back into the runtime from which HotSpotJVMCIRuntime.translate was called.

              dnsimon Douglas Simon
              dnsimon Douglas Simon
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: