RFR: 8282322: AArch64: Provide a means to eliminate all STREX family of instructions [v3]
Dmitry Chuyko
dchuyko at openjdk.java.net
Mon May 23 16:12:34 UTC 2022
> On AArch64 it is sometimes convenient to have LSE atomics right from the start. Currently they are enabled after feature detection and RR reverse debugger works incorrectly.
>
> New build configuration feature 'hardlse' is added. If it is enabled for aarch64 type of build, then statically compiled stubs replace the initial pessimistic implementation and dynamically generated replacements (when LSE support is detected). The feature works for builds of all debug levels.
>
> New file atomic_linux_aarch64_lse.S is derived from atomic_linux_aarch64.S and inherits its copyright. This alternative static implementation corresponds to the dynamically generated code.
>
> Note, this configuration part is necessary but not sufficient to fully avoid strex instructions for practical purposes. Other parts are:
>
> * Run on the OS built without strex family instructions. E.g. Amazon Linux 2022.
> * Compile with outline atomics enabled and the configuration flag enabled. E.g. configure with
> --with-extra-cflags='-march=armv8.3-a+crc+crypto -moutline-atomics' --with-extra-cxxflags='-march=armv8.3-a+crc+crypto -moutline-atomics' --with-extra-ldflags='-Wl,--allow-multiple-definition' --with-jvm-features=hardlse
>
> Testing: tier1, tier2 on linux-aarch64 release builds with feature off and feature on.
Dmitry Chuyko has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains five additional commits since the last revision:
- Merge branch 'openjdk:master' into JDK-8282322
- Use LSE in linux-aarch64 asm code if __ARM_FEATURE_ATOMICS is on
- Revert "hardlse feature"
This reverts commit c5da85d3282bb995f69639f8f592cc94560916c5.
- Merge branch 'openjdk:master' into JDK-8282322
- hardlse feature
-------------
Changes:
- all: https://git.openjdk.java.net/jdk/pull/8779/files
- new: https://git.openjdk.java.net/jdk/pull/8779/files/1287cce3..f7c8378a
Webrevs:
- full: https://webrevs.openjdk.java.net/?repo=jdk&pr=8779&range=02
- incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=8779&range=01-02
Stats: 8571 lines in 343 files changed: 4112 ins; 3026 del; 1433 mod
Patch: https://git.openjdk.java.net/jdk/pull/8779.diff
Fetch: git fetch https://git.openjdk.java.net/jdk pull/8779/head:pull/8779
PR: https://git.openjdk.java.net/jdk/pull/8779
More information about the build-dev
mailing list