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

[JVMCI] reduce JNI overhead and other VM rounds trips in JVMCI

    XMLWordPrintable

Details

    • b05

    Description

      The interface between HotSpot and libjvmci is implemented via JNI. Every time HotSpot C++ code needs to read libjvmci objects, it requires 4 VM transitions:
      1. HotSpot: VM to native (_thread_in_vm -> _thread_in_native)
      2. SVM: Native to VM (entering SVM)
      3. SVM: VM to native (exiting SVM)
      4. HotSpot: Native to VM (_thread_in_native -> _thread_in_vm)

      When processing a HotSpotCompiledCode object during code installation (i.e. CodeInstaller::install), the overhead of all these transitions is significant.

      There are other inefficiencies in the JVMCI Java/C++ interactions such as a VM round trip to create the class name string when converting a Klass* value to a ResolvedJavaType value.

      This issue exists to remove or reduce the above inefficiencies.

      Attachments

        Issue Links

          Activity

            People

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

              Dates

                Created:
                Updated:
                Resolved: