RFR: 8327647: Occasional SIGSEGV in markWord::displaced_mark_helper() for SPECjvm2008 sunflow [v4]
Dean Long
dlong at openjdk.org
Fri Apr 19 22:59:28 UTC 2024
On Thu, 18 Apr 2024 17:19:30 GMT, Matias Saavedra Silva <matsaave at openjdk.org> wrote:
>> A misplaced memory barrier causes a very intermittent crash on on some aarch64 systems. This patch adds an appropriate LoadLoad barrier after a constant pool cache field entry is loaded. Verified with tier 1-5 tests.
>
> Matias Saavedra Silva has updated the pull request incrementally with one additional commit since the last revision:
>
> Fei comments
If I understand correctly, the order of writes must be:
1. ResolvedFieldEntry fields, except _get_code and _put_code
2. _get_code, _put_code
3. patch_bytecode(fast_bytecode)
so the order of reads must be reversed. That's why there are load-acquires when reading _get_code and _put_code.
After [3] is done, after dispatching to fast_bytecode, we need to do a LoadLoad between the already read fast bytecode [3] and the "cache" fields [1]. The LoadLoad is not for the load of the next bytecode that will be done in dispatch_next().
-------------
PR Comment: https://git.openjdk.org/jdk/pull/18477#issuecomment-2067373161
More information about the hotspot-compiler-dev
mailing list