Integrated: 8366038: Thread::SpinRelease should use Atomic::release_store
Anton Artemov
duke at openjdk.org
Thu Sep 4 04:38:52 UTC 2025
On Mon, 1 Sep 2025 14:34:29 GMT, Anton Artemov <duke at openjdk.org> wrote:
> Hi, please consider the following changes:
>
> `Thread::SpinRelease()` uses an `OrderAccess::fence()` to prevent loads and stores from within the critical section to float down out of the section. A full fence is expensive and it is an overkill on most platforms. Instead, one can achieve the same effect with `Atomic::release_store()`.
>
> Tested in tiers 1 - 3.
This pull request has now been integrated.
Changeset: 4d1dfabc
Author: Anton Artemov <anton.artemov at oracle.com>
Committer: David Holmes <dholmes at openjdk.org>
URL: https://git.openjdk.org/jdk/commit/4d1dfabcb4e94601995b07b7ecea4249ae375a04
Stats: 5 lines in 1 file changed: 0 ins; 2 del; 3 mod
8366038: Thread::SpinRelease should use Atomic::release_store
Reviewed-by: dholmes, ayang
-------------
PR: https://git.openjdk.org/jdk/pull/27035
More information about the hotspot-runtime-dev
mailing list