RFR: JDK-6545967: sp05t003 failed ResumeThread() due to THREAD_NOT_SUSPENDED

Gary Adams gary.adams at oracle.com
Tue Jun 19 18:42:49 UTC 2018


There are some rare race conditions that impact some jvmti tests that
suspend and resume threads. These tests were recently moved into
the open repos.

   Webrev: http://cr.openjdk.java.net/~gadams/6545967/webrev.00/

The fix in hs203t003 replaces a blind 10 second sleep, with a specific
check to wait for a redefineClass to be performed, which takes place as
part of callbackFieldAccess. This let's the rest of the operations be 
performed
at a known point in the test sequence.

The fix in sp05t003 moves the incrementing of the counters to after the
suspend thread calls. The agentProc function is watching the counters to 
know
when to continue processing and eventually resuming of the suspended 
threads.



More information about the serviceability-dev mailing list