[jdk18] RFR: 8278389: SuspendibleThreadSet::_suspend_all should be volatile/atomic [v3]

Hamlin Li mli at openjdk.java.net
Thu Dec 16 10:50:56 UTC 2021


On Mon, 13 Dec 2021 11:10:53 GMT, Thomas Schatzl <tschatzl at openjdk.org> wrote:

>> Hi all,
>> 
>> can I have reviews for this change that makes SuspendibleThreadSet::_suspend_all volatile and all accesses to it use Atomic helpers?
>> 
>> I found that the only getter for that member is called SuspendibleThreadSet::should_yield(), which contradicts our naming rules; to keep the change minimal (and the naming discussion out of this PR because I do not feel that _suspend_all is particularly good) I introduced a private suspend_all() method.
>> I can of course add some renaming in this change (but then for jdk19+ only).
>> 
>> Testing: gha, local compilation
>> 
>> Thanks,
>> Thomas
>
> Thomas Schatzl has updated the pull request incrementally with two additional commits since the last revision:
> 
>  - Revert of dummy change
>  - Another dummy change

Marked as reviewed by mli (Reviewer).

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

PR: https://git.openjdk.java.net/jdk18/pull/10



More information about the hotspot-gc-dev mailing list