[riscv-port] RFR: 8277431: riscv: Intrinsify recursive ObjectMonitor locking for C2
According to https://bugs.openjdk.java.net/browse/JDK-8277180, the C2 fast_lock and fast_unlock intrinsics don't support recursive ObjectMonitor locking. Some workload can significantly benefit from this. This fixes the problem on riscv. Tier1 tests of hotspot and jdk are passed on unmatched and all JTreg tests are tested on qemu without new failures. ------------- Commit messages: - 8277431: riscv: Intrinsify recursive ObjectMonitor locking for C2 Changes: https://git.openjdk.java.net/riscv-port/pull/13/files Webrev: https://webrevs.openjdk.java.net/?repo=riscv-port&pr=13&range=00 Issue: https://bugs.openjdk.java.net/browse/JDK-8277431 Stats: 21 lines in 1 file changed: 20 ins; 1 del; 0 mod Patch: https://git.openjdk.java.net/riscv-port/pull/13.diff Fetch: git fetch https://git.openjdk.java.net/riscv-port pull/13/head:pull/13 PR: https://git.openjdk.java.net/riscv-port/pull/13
On Tue, 23 Nov 2021 07:02:33 GMT, Yadong Wang <yadongwang@openjdk.org> wrote:
According to https://bugs.openjdk.java.net/browse/JDK-8277180, the C2 fast_lock and fast_unlock intrinsics don't support recursive ObjectMonitor locking. Some workload can significantly benefit from this. This fixes the problem on riscv. Tier1 tests of hotspot and jdk are passed on unmatched and all JTreg tests are tested on qemu without new failures.
It would be interesting to know how this may affect performance on riscv. Maybe we can try DaCapo h2 to see. ------------- PR: https://git.openjdk.java.net/riscv-port/pull/13
On Tue, 23 Nov 2021 11:07:09 GMT, Fei Yang <fyang@openjdk.org> wrote:
It would be interesting to know how this may affect performance on riscv. Maybe we can try DaCapo h2 to see.
DaCapo results are updated. ------------- PR: https://git.openjdk.java.net/riscv-port/pull/13
On Tue, 23 Nov 2021 07:02:33 GMT, Yadong Wang <yadongwang@openjdk.org> wrote:
According to https://bugs.openjdk.java.net/browse/JDK-8277180, the C2 fast_lock and fast_unlock intrinsics don't support recursive ObjectMonitor locking. Some workload can significantly benefit from this. This fixes the problem on riscv.
Tier1 tests of hotspot and jdk are passed on unmatched and all JTreg tests are tested on qemu without new failures.
[The original performance regression after JDK-8253064](https://bugs.openjdk.java.net/browse/JDK-8263864) was resolved by this intrinsic. The benchmark ran on unmatched:
dacapo-9.12-MR1-bach.jar h2 -s huge -t 1 -n 1
Non-intrisified recursive fast_lock/fast_unlock: ===== DaCapo 9.12-MR1 h2 PASSED in 2614652 msec ===== Intrisified recursive fast_lock/fast_unlock: ===== DaCapo 9.12-MR1 h2 PASSED in 2027247 msec =====
The performance numbers looks great. Thanks. ------------- Marked as reviewed by fyang (Lead). PR: https://git.openjdk.java.net/riscv-port/pull/13
On Tue, 23 Nov 2021 07:02:33 GMT, Yadong Wang <yadongwang@openjdk.org> wrote:
According to https://bugs.openjdk.java.net/browse/JDK-8277180, the C2 fast_lock and fast_unlock intrinsics don't support recursive ObjectMonitor locking. Some workload can significantly benefit from this. This fixes the problem on riscv.
Tier1 tests of hotspot and jdk are passed on unmatched and all JTreg tests are tested on qemu without new failures.
[The original performance regression after JDK-8253064](https://bugs.openjdk.java.net/browse/JDK-8263864) was resolved by this intrinsic. The benchmark ran on unmatched:
dacapo-9.12-MR1-bach.jar h2 -s huge -t 1 -n 1
Non-intrisified recursive fast_lock/fast_unlock: ===== DaCapo 9.12-MR1 h2 PASSED in 2614652 msec ===== Intrisified recursive fast_lock/fast_unlock: ===== DaCapo 9.12-MR1 h2 PASSED in 2027247 msec =====
This pull request has now been integrated. Changeset: a319e9ab Author: Yadong Wang <yadongwang@openjdk.org> Committer: Fei Yang <fyang@openjdk.org> URL: https://git.openjdk.java.net/riscv-port/commit/a319e9aba1eddb558fd4fa0c6c85e... Stats: 21 lines in 1 file changed: 20 ins; 1 del; 0 mod 8277431: riscv: Intrinsify recursive ObjectMonitor locking for C2 Reviewed-by: fyang ------------- PR: https://git.openjdk.java.net/riscv-port/pull/13
participants (2)
-
Fei Yang
-
Yadong Wang