RFR: 8257831: Suspend with handshakes [v6]
Robbin Ehn
rehn at openjdk.java.net
Tue Apr 13 07:26:21 UTC 2021
On Tue, 13 Apr 2021 02:41:41 GMT, David Holmes <dholmes at openjdk.org> wrote:
>> Robbin Ehn has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains eight commits:
>>
>> - Merge branch 'master' into SuspendInHandshake
>> - Review fixes 2
>> - White space fixes
>> - Merge branch 'master' into SuspendInHandshake
>> - Review fixes
>> - Merge branch 'master' into SuspendInHandshake
>> - Merge branch 'master' into SuspendInHandshake
>> - 8257831: Suspend with handshake (review baseline)
>
> src/hotspot/share/runtime/objectMonitor.cpp line 447:
>
>> 445: // Completed the tranisition.
>> 446: SafepointMechanism::process_if_requested(current);
>> 447: current->set_thread_state(_thread_in_vm);
>
> I feel very uncomfortable that we remain _thread_blocked_trans across such a lengthy chunk of code - particularly the call to exit()! This is an abuse of the trans states which are only supposed to exist and be used to ensure the correctness of the Dekker-duality when setting and reading the thread state.
>
> And I still would prefer to see these state changes and related safepoint-mechanism checks encapsulated somehow.
Yes we should figure out something here.
Note that we use to call exit() while blocked.
-------------
PR: https://git.openjdk.java.net/jdk/pull/3191
More information about the hotspot-runtime-dev
mailing list