RFR: 8264393: JDK-8258284 introduced dangling TLH race [v2]
Daniel D.Daugherty
dcubed at openjdk.java.net
Wed Mar 31 01:57:41 UTC 2021
On Wed, 31 Mar 2021 00:28:19 GMT, David Holmes <dholmes at openjdk.org> wrote:
>> Daniel D. Daugherty has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Fix two more ThreadsListHandle tests.
>
> Hi Dan,
>
> So in a nutshell, when clearing a nested TLH you can't simply install the previous TLH as the threads_hazard_ptr, but instead set to NULL so that it is properly set by acquire_stable_list.
>
> This seems reasonable to me.
>
> Thanks,
> David
@dholmes-ora - your nutshell summary is spot on. Thanks for the review.
> src/hotspot/share/runtime/threadSMR.cpp line 542:
>
>> 540: // And that protocol cannot be properly done with a ThreadsList that
>> 541: // might not be the current system ThreadsList.
>> 542: assert(_previous->_list->_nested_handle_cnt > 0, "must be > than zero");
>
> Nit: "> than" reads "greater than than".
Fixed.
-------------
PR: https://git.openjdk.java.net/jdk/pull/3272
More information about the hotspot-runtime-dev
mailing list