RFR: 8317600: VtableStubs::stub_containing() table load not ordered wrt to stores
Dean Long
dlong at openjdk.org
Mon Oct 9 23:07:14 UTC 2023
On Thu, 5 Oct 2023 14:20:41 GMT, Thomas Schatzl <tschatzl at openjdk.org> wrote:
> Hi all,
>
> please review this change that makes sure that `Vtablestubs::stub_containing()` (and `::vtable_stub_do()` I noticed while implementing this) use proper memory fences to correctly observe the next pointers in the hash table buckets.
>
> I assume that this memory ordering issue never occurs in the wild, there is probably always some additional memory fencing between the addition of the element to the given bucket to the iteration. However it is still the more correct code (I believe) to explicitly enforce memory ordering.
>
> Testing: gha, class unloading stress test
>
> Thanks,
> Thomas
Marked as reviewed by dlong (Reviewer).
OK, I mis-read Atomic:load as meaning load_acquire for some reason.
-------------
PR Review: https://git.openjdk.org/jdk/pull/16056#pullrequestreview-1665521464
PR Comment: https://git.openjdk.org/jdk/pull/16056#issuecomment-1754032551
More information about the hotspot-compiler-dev
mailing list