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

Store method handle linkers in the 'non-nmethods' heap

    XMLWordPrintable

    Details

    • Type: Enhancement
    • Status: Open
    • Priority: P4
    • Resolution: Unresolved
    • Affects Version/s: 17
    • Fix Version/s: tbd
    • Component/s: hotspot
    • Labels:
      None

      Description

      Raised after the discussion in this PR thread:

      https://github.com/openjdk/jdk/pull/2523#discussion_r587460031

      "I don't see a compelling reason why method handle linkers have to be nmethods and live in 'profiled'/'non-profiled' code heaps. I think the reason why it works that way now is the linkers are treated as ordinary native wrappers (since linker methods are just signature-polymorphic native static methods declared on java.lang.invoke.MethodHandle class). But native wrappers are represented as nmethods for a reason: they can be unloaded along with the class.
      It's not the case with MH linkers which aren't unloaded at all."

      MH linkers aren't unloaded and therefore could be stored in the 'non-nmethods' heap. It would be nice to investigate such a solution and it's benefits / drawbacks.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              enikitin Evgeny Nikitin
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated: