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

AArch64: the const STUB_THRESHOLD in macroAssembler_aarch64.cpp needs to be tuned

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: 14
    • Fix Version/s: 15
    • Component/s: hotspot
    • Subcomponent:
    • Resolved In Build:
      b03
    • CPU:
      aarch64
    • OS:
      linux

      Description

      MacroAssembler::string_compare intrinsic has a STUB_THRESHOLD
      = 64 + 8 to control the stub replacement.

      http://hg.openjdk.java.net/jdk/jdk/file/4aea554692aa/src/hotspot/cpu/aarch64/macroAssembler_aarch64.cpp#l4848

      Per JMH string benchmarks testing, with Ampere eMAG system, the stub code can be beneficial to shorter Strings (less than 72 chars for UTF16, or 72 bytes for Latin if COMPACT_STRING is on) as well, up to 1.5x gain in some cases.

      Suggest to make it tunable so one can configure it per systems once the performance impact (positive or negative) got proved via testing. And this can avoid potential side-effect caused by a fixed value on different aarch64 systems.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                qpzhang Patrick Zhang
                Reporter:
                qpzhang Patrick Zhang
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: