RFR: 8312174: missing JVMTI events from vthreads parked during JVMTI attach [v2]
Serguei Spitsyn
sspitsyn at openjdk.org
Fri Sep 8 13:56:41 UTC 2023
On Wed, 6 Sep 2023 20:33:46 GMT, Alex Menkov <amenkov at openjdk.org> wrote:
>> Serguei Spitsyn has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains two additional commits since the last revision:
>>
>> - Merge
>> - 8312174: missing JVMTI events from vthreads parked during JVMTI attach
>
> test/hotspot/jtreg/serviceability/jvmti/vthread/VThreadEventTest/VThreadEventTest.java line 149:
>
>> 147: for (int sleepNo = 0; sleepNo < 10 && threadEndCount() < THREAD_CNT; sleepNo++) {
>> 148: log("main: wait iter: " + sleepNo);
>> 149: Thread.sleep(100);
>
> sleep(1000)? (comment before the loop tells about 10 secs)
Good catch. Leonid suggested to make waiting with unlimited sleeps, so the test timeout will work.
Made it like below:
// wait until all VirtualThreadEnd events are sent
while (int sleepNo = 1; threadEndCount() < THREAD_CNT; sleepNo++) {
if (sleepNo % 100 == 0) { // 10 sec period of waiting
log("main: wait iter: " + sleepNo);
}
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/15467#discussion_r1319903293
More information about the hotspot-dev
mailing list