-
Bug
-
Resolution: Fixed
-
P4
-
19, 21
ThreadMXBean is specified to provide a monitoring or management interface for platform threads, it is specified to not support virtual threads.
At this time, ThreadMXBean::isCurrentThreadCpuTimeSupported returns true when invoked from a virtual thread, it should return false.
Additionally, when using the alternative implementation of virtual threads (-XX:-VMContinuations), there are a few issues:
- getThreadXXXTime returns cpu/user time for virtual threads, it should set the elements corresponding to virtual threads to 1L.
- getThreadAllocatedBytes returns the allocation by virtual threads, it should set the elements corresponding to virtual threads to 1L.
At this time, ThreadMXBean::isCurrentThreadCpuTimeSupported returns true when invoked from a virtual thread, it should return false.
Additionally, when using the alternative implementation of virtual threads (-XX:-VMContinuations), there are a few issues:
- getThreadXXXTime returns cpu/user time for virtual threads, it should set the elements corresponding to virtual threads to 1L.
- getThreadAllocatedBytes returns the allocation by virtual threads, it should set the elements corresponding to virtual threads to 1L.
- csr for
-
JDK-8303251 ThreadMXBean issues with virtual threads
-
- Closed
-