RFR: 8346792: serviceability/jvmti/vthread/GetThreadState/GetThreadState.java testObjectWaitMillis failed [v11]

Serguei Spitsyn sspitsyn at openjdk.org
Thu Jan 30 12:15:28 UTC 2025


On Thu, 30 Jan 2025 12:04:50 GMT, Serguei Spitsyn <sspitsyn at openjdk.org> wrote:

>> src/hotspot/share/services/threadService.hpp line 493:
>> 
>>> 491:     JavaThreadStatusChanger(java_thread,
>>> 492:                             interruptible ? (timed ? JavaThreadStatus::IN_OBJECT_WAIT_TIMED : JavaThreadStatus::IN_OBJECT_WAIT)
>>> 493:                                           : java_lang_Thread::get_thread_status(java_thread->threadObj())) {
>> 
>> I think we need some explanatory comments here. It took me a while to understand how interruptible==false caused this to all be a (very inefficient) no-op. Thanks
>
> Thanks. I've tried to explain it at line 494. But you are right, I'll add an explaning comment.

Fixed now.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/23126#discussion_r1935507530


More information about the hotspot-runtime-dev mailing list