RFR: 8351927: Change VirtualThread implementation to use use FJP delayed task handling
Viktor Klang
vklang at openjdk.org
Wed Apr 9 08:46:36 UTC 2025
On Thu, 13 Mar 2025 10:48:14 GMT, Alan Bateman <alanb at openjdk.org> wrote:
> Follow up to JDK-8319447 to change the VirtualThread implementation to use FJP's delayed task handling.
>
> The SPTE based implementation is not removed. It will continue to be used by tests. If custom schedulers are exposed in the future then they will use this implementation.
>
> For timed-Object.wait, waitTimeoutExpired is changed to use lazySubmit to avoid signalling and increase the chance that the unparked virtual thread will continue on the current carrier. For timed-park, the timeout task is changed to reduced form of unpark that also uses lazySubmit, for the same reason.
>
> `jcmd Thread.vthread_scheduler` is changed to no longer print the delay schedulers. Instead, the delayed task count will appear in the default scheduler output.
Marked as reviewed by vklang (Reviewer).
-------------
PR Review: https://git.openjdk.org/jdk/pull/24030#pullrequestreview-2752606260
More information about the serviceability-dev
mailing list