On Tue, 18 Jun 2024 11:11:12 GMT, Alan Bateman <al...@openjdk.org> wrote:
>> Inigo Mediavilla Saiz has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Improve assert and document conditional print > > I looked at the changes in the latest revision (9a954efe) and they look okay, > it basically skips printing the mounted virtual thread when that virtual > thread is interacting with the scheduler or timer mechanism, the so called > "temporary transitions" that are needed to ensure the correct identity when > submitting tasks to the scheduler, and to avoid deadlock when submitting > tasks to the scheduler requires locking. It also changes the test so testing > with JTREG_TEST_THREAD_FACTORY=Virtual won't observe the dummy thread in a > temporary transition. > > We can improve on this in the loom repo as JavaThread has the thread ID of > the mounted virtual thread. Note that the pre-existing "Carrying ..." line > has the same issue as we've been discussing here, it just hasn't been noticed > perhaps. > > One thing that I think we should do is remove the thread name from the > "Mounted ..." line. I initially thought this was a good idea but there is no > reference to this when a virtual thread is mounted and interacting with the > scheduler. Virtual threads don't have a name by default so it's not a big a > loss as you might think. We can of course re-visit this in the future. Thanks again ! @AlanBateman @dholmes-ora, I've responded to your latest comments and incorporated your latest suggestions. ------------- PR Comment: https://git.openjdk.org/jdk/pull/19744#issuecomment-2176105017