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

Improve jlink VersionPropsPlugin

    XMLWordPrintable

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 15
    • Component/s: tools
    • Labels:
      None
    • Subcomponent:
    • Resolved In Build:
      b19

      Description

      With JDK-8232080, a jlink plugin to modify vendor specific system properties in runtime images created with jlink was introduced.
      The plugin modifies the bytecode of class java.lang.VersionProps to initialize certain properties to a configurable value.

      The static class initializer is rewritten, using java-asm, to intercept the putstatic bytecode that loads the field value, pops the top operand of the stack and emits another ldc instruction to load the new value from the constant pool.

      This can be optimized to replace the original ldc instruction with the ldc that loads the new value, removing the additonal pop and ldc bytecodes.

        Attachments

          Activity

            People

            Assignee:
            clanger Christoph Langer
            Reporter:
            clanger Christoph Langer
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: