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

Failure during CompileOnly parsing leads to ShouldNotReachHere

    XMLWordPrintable

Details

    • b06

    Backports

      Description

        java -Xcomp -XX:CompileOnly=,

        # A fatal error has been detected by the Java Runtime Environment:
        #
        # Internal Error (workspace/open/src/hotspot/share/compiler/compilerOracle.cpp:1061), pid=1823394, tid=1823395
        # Error: ShouldNotReachHere()
        #
        # JRE version: (21.0+25) (fastdebug build )
        # Java VM: Java HotSpot(TM) 64-Bit Server VM (fastdebug 21-ea+25-LTS-2118, compiled mode, sharing, tiered, compressed oops, compressed class ptrs, g1 gc, linux-amd64)
        # Problematic frame:
        # V [libjvm.so+0xa2240e] CompilerOracle::parse_compile_only(char*)+0x71e

        Stack: [0x00007f4a20a21000,0x00007f4a20b22000], sp=0x00007f4a20b202b0, free space=1020k
        Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
        V [libjvm.so+0xa2240e] CompilerOracle::parse_compile_only(char*)+0x71e (compilerOracle.cpp:1061)
        V [libjvm.so+0xa2258f] compilerOracle_init()+0x10f
        V [libjvm.so+0xe25a0a] init_globals()+0xaa
        V [libjvm.so+0x17b0825] Threads::create_vm(JavaVMInitArgs*, bool*)+0x2c5
        V [libjvm.so+0xf882b5] JNI_CreateJavaVM+0x75
        C [libjli.so+0x3b0f] JavaMain+0x8f
        C [libjli.so+0x79d9] ThreadJavaMain+0x9

        The issue was fixed as a side effect of JDK-8027711 in JDK 22 b02. The VM now prints an error:

        CompileOnly: An error occurred during parsing
        Line: ','
        Error: Could not create the Java Virtual Machine.
        Error: A fatal exception has occurred. Program will exit.

        Since a backport of JDK-8027711 is not an option, we might want to extract a point-fix for JDK < 22.

        Attachments

          Issue Links

            Activity

              People

                thartmann Tobias Hartmann
                thartmann Tobias Hartmann
                Votes:
                0 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: