On Thu, 17 Sep 2020 19:23:09 GMT, Robbin Ehn <[email protected]> wrote:
>> src/hotspot/share/runtime/handshake.cpp line 508:
>>
>>> 506: assert(op->_target == NULL || _handshakee == op->_target, "Wrong
>>> thread");
>>> 507: log_trace(handshake)("Processing handshake " INTPTR_FORMAT " by
>>> %s", p2i(op),
>>> 508: executioner_name(current_thread,
>>> _handshakee, op == match_op));
>>
>> With the above change we could even avoid factoring the code into
>> executioner_name() and just do:
>> log_trace(handshake)("Processing handshake " INTPTR_FORMAT " by %s%s",
>> p2i(op),
>> op == match_op ? "handshaker" :
>> "cooperative",
>> current_thread->is_VM_thread() ?
>> "(VM Thread)" : "(JavaThread)");
>
> I added a second log line where I use that function also:
> log_trace(handshake)("Thread %s(" INTPTR_FORMAT ") executed %d ops for
> JavaThread: " INTPTR_FORMAT " %s target op: "
> INTPTR_FORMAT,
> executioner_name(current_thread, _handshakee, pr_ret
> == HandshakeState::_succeed),
> p2i(current_thread), executed, p2i(_handshakee),
> pr_ret == HandshakeState::_succeed ? "including" :
> "excluding", p2i(match_op));
Push commit 469f8fc, please have a look.
-------------
PR: https://git.openjdk.java.net/jdk/pull/151