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

Performance issue with MethodHandle.asCollector

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 17
    • Component/s: core-libs
    • Labels:
      None

      Description

      See discussion here:

      https://mail.openjdk.java.net/pipermail/mlvm-dev/2021-March/006895.html

      MethodHandles.collectArguments with an appropriate filter function is faster than MethodHandle.asCollector, which appears to copy arrays under some circumstances.

      The code of MethodHandles.collectArguments and MethodHandle.asCollector is very similar (unsurprisingly), perhaps indicating some localized adjustment to the latter may be possible to fix the issue.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              jvernee Jorn Vernee
              Reporter:
              psandoz Paul Sandoz
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: