RFR: 8261838: Shenandoah: reconsider heap region iterators memory ordering
Roman Kennke
rkennke at openjdk.java.net
Tue Feb 16 19:32:40 UTC 2021
On Tue, 16 Feb 2021 19:13:03 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:
> We use CASes to distributed workers between regions. Hotspot's default for atomic operations is memory_order_conservative, which emits two-way memory fences around the CASes at least on AArch64 and PPC64.
>
> This seems to be excessive for region distribution code, and "relaxed" is enough, since we don't piggyback memory ordering on these.
>
> This also calls for some refactoring in the code itself.
>
> Additional testing:
> - [x] `hotspot_gc_shenandoah`
> - [ ] Ad-hoc performance runs
Looks good!
-------------
Marked as reviewed by rkennke (Reviewer).
PR: https://git.openjdk.java.net/jdk/pull/2593
More information about the hotspot-gc-dev
mailing list