[jdk17u-dev] RFR: 8357968: RISC-V: Interpreter volatile reference stores with G1 are not sequentially consistent
Feilong Jiang
fjiang at openjdk.org
Wed Jun 25 15:12:08 UTC 2025
Fixes RISC-V memory ordering problem.
This patch is not clean because [JDK-8293290](https://bugs.openjdk.org/browse/JDK-8293290) adds a third temporary register to `store_heap_oop`, which is introduced in JDK20.
In JDK17, `do_oop_store` also clobbers the same `x13` as in mailine. The current fix is similar to aarch64 fixes in mainline, but puts the flags in `x15` instead, to avoid the clobber of the volatile bits.
Additional testing:
- [x] linux-riscv64 server release, jcstress RefDekker test now passes
- [ ] linux-riscv64 server release, Tier1-3
-------------
Commit messages:
- Backport c5a1543ee3e68775f09ca29fb07efd9aebfdb33e
Changes: https://git.openjdk.org/jdk17u-dev/pull/3678/files
Webrev: https://webrevs.openjdk.org/?repo=jdk17u-dev&pr=3678&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8357968
Stats: 8 lines in 1 file changed: 4 ins; 0 del; 4 mod
Patch: https://git.openjdk.org/jdk17u-dev/pull/3678.diff
Fetch: git fetch https://git.openjdk.org/jdk17u-dev.git pull/3678/head:pull/3678
PR: https://git.openjdk.org/jdk17u-dev/pull/3678
More information about the jdk-updates-dev
mailing list