On Wed, 28 Feb 2024 05:28:00 GMT, Chris Plummer <[email protected]> wrote:
>> test/jdk/com/sun/jdi/InterruptHangTest.java line 140:
>>
>>> 138: }
>>> 139:
>>> 140: if (!remoteMode) { // we don't count interruptsSent when in
>>> remote mode
>>
>> Nit: This is a little bit confusing. In fact the `interruptsSent` is counted
>> at the line 215.
>> The comment should probably say that we do not care (do not compare)
>> this counter in the remote mode. Would it better to just print this counter
>> unconditionally?
>
> `interruptsSent` is counted by the PreciseInterruptor and
> AggressiveInterruptor threads, which are in the same process, so we can print
> it here. When in remote mode, the counting is done by the RemoteInterruptor
> thread, which is in a different process, so we can't print it here. The
> RemoteInterruptor does print the count when it is done.
Okay, I see. But the comments is still confusing and needs an update.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/17989#discussion_r1505433084