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

Partial in-lining for vectorized mismatch operation using AVX512 masked instructions

    XMLWordPrintable

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 17
    • Fix Version/s: 17
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
    • Resolved In Build:
      b26
    • CPU:
      x86

      Description

      ArraySupport.vectorizedMismatch is a leaf level comparison routine which gets called by various public Java APIs (Arrays.equals, Arrays.mismatch).
      Hotspot C2 compiler intrinsifies vectorizedMismatch routine and emits a call to a stub routine which uses vector instruction to compare the inputs.

      For small compare operation whose size fits in one vector register i.e. < 32 bytes or <= 64 bytes, compiler can employ partial in-lining technique to emit the fast path code at the call site which does vector comparison under the influence of a predicate register/mask computed a function of comparison length.

      If the length of comparison is greater than the vector register size then the slow path comprising of stub call could be taken.

      This shall prevent the call overhead associated with stub call which could be significant compared to actual comparison operation for small sized comparisons.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              jbhateja Jatin Bhateja
              Reporter:
              jbhateja Jatin Bhateja
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: