RFR: 8332923: ObjectMonitorUsage.java failed with unexpected waiter_count [v3]

David Holmes dholmes at openjdk.org
Thu May 30 07:27:02 UTC 2024


On Thu, 30 May 2024 07:14:13 GMT, Alan Bateman <alanb at openjdk.org> wrote:

>> Okay. I still think that should be hidden behind the `java_lang_VirtualThread::is_instance` as it is an implementation detail the JVMTI and thread code shouldn't need to know about IMO. Once the alternative implementation is removed I expect these explicit checks for `BaseVirtualThread` will need to be reverted and we could avoid that if we make a change now.
>
> java_lang_VirtualThread::is_instance returning true when the top is not an instance of that class would be a bit strange. java_lang_Thread::is_virtual_thread_instance might be less surprising.

Yes you are right, we would need a new API to answer the generic "are you a virtual thread" query.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/19405#discussion_r1620123058


More information about the serviceability-dev mailing list