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

SA does not include JVMCI Compiler threads in heap dump

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P4 P4
    • tbd
    • 25
    • hotspot
    • None

      In SA, CompilerThread::isHiddenFromExternalView() always returns true. However, for hotspot CompilerThread::is_hidden_from_external_view() returns false if JVMCI is being used and LibJVMCICompilerThreadHidden is set false. It is true by default, and is set false when users want to be able to use a java debugger to debug JVMCI. The one area of SA that this bug impacts is in HeapHprofBinWriter::dumpStackTraces(), which will skip over the JVMCI Compiler thread because CompilerThread::is_hidden_from_external_view() always returns true. It should not skip the JVMCI Compiler thread if LibJVMCICompilerThreadHidden is false (and EnableJVMCI is true). However, you could also argue that for SA, LibJVMCICompilerThreadHidden should be ignored and CompilerThread::isHiddenFromExternalView() should always return false for JVMCI Compiler threads. In either case, CompilerThread::isHiddenFromExternalView() needs to be modified to do a better job for JVMCI Compiler threads.

      Note, just because JVMCI is enable (ie you are using Graal) doesn't mean a CompilerThread is running java code. There is still a C1 CompilerThread, and the JVMCI CompilerThread(s) might be running the native version of Graal, not the java version. This means simply checking runtime flags to determine JVMCI usage is not really correct, although might be good enough for SA.

            Unassigned Unassigned
            cjplummer Chris Plummer
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: