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

Remove invokedynamic cache index encoding

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 23
    • 23
    • hotspot
    • b20

      Before JDK-8307190, JDK-8309673, and JDK-8301995, invokedynamic operands needed to be rewritten to encoded values to better distinguish indy entries from other cp cache entries. The above changes now distinguish between entries with to_cp_index() using the bytecode, which is now propagated by the callers.

      Encode calls need matching decode calls, which can be easily forgotten and can lead to issues such as the following exception when using revptrs:

      hsdb> revptrs 0x00007f2e8c06c000
      Computing reverse pointers...
      Error: java.lang.ArrayIndexOutOfBoundsException: -1 2
      java.lang.ArrayIndexOutOfBoundsException: -1 2

      Thanks to the above changes, it is no longer necessary to encode the indy indices, so these methods can be removed.

            matsaave Matias Saavedra Silva
            matsaave Matias Saavedra Silva
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: