Integrated: 8374679: ZGC: Convert zForwardingAllocator to use Atomic<T>

Axel Boldt-Christmas aboldtch at openjdk.org
Mon Jan 26 14:17:00 UTC 2026


On Wed, 14 Jan 2026 08:29:43 GMT, Axel Boldt-Christmas <aboldtch at openjdk.org> wrote:

> Convert usages of AtomicAccess to Atomic<T> in zForwardingAllocator.
> 
> We currently use  plain loads and stores which are synchronised and ordered with respect to the allocation by means of us starting worker threads which allocate and awaiting them to finish. This patch changes everything to have atomic semantics, but the loads and stores are still relaxed. 
> 
> Testing:
>  * GHA
>  * HotSpot GC tests with ZGC linux x64 and linux aarch64

This pull request has now been integrated.

Changeset: fef85ff9
Author:    Axel Boldt-Christmas <aboldtch at openjdk.org>
URL:       https://git.openjdk.org/jdk/commit/fef85ff932055cd5385633f3b283e6201cdcaa68
Stats:     12 lines in 3 files changed: 2 ins; 1 del; 9 mod

8374679: ZGC: Convert zForwardingAllocator to use Atomic<T>

Reviewed-by: stefank, tschatzl

-------------

PR: https://git.openjdk.org/jdk/pull/29221


More information about the hotspot-gc-dev mailing list