Re: RFR [7181748] TEST_BUG: java/lang/ThreadGroup/Suspend test fails intermittently

2013-06-13 Thread Ivan Gerasimov
Thank you Chris, I would really appreciate your sponsor's help! Here's the patch for this change: http://cr.openjdk.java.net/~igerasim/2commit/7181748-jdk8-Suspend-test-fails.patch Sincerely yours, Ivan On 13.06.2013 14:35, Chris Hegarty wrote: The updated webrev looks good to me Ivan. Sorry

Re: RFR [7181748] TEST_BUG: java/lang/ThreadGroup/Suspend test fails intermittently

2013-06-13 Thread David Holmes
Thumbs up from me. These tests can never be perfect, but this addresses the problem that was being observed. Of course now it might just shift the problem ... David On 13/06/2013 8:33 PM, Ivan Gerasimov wrote: Thank you, David. I've reverted the code back, added volatile specification to th

Re: RFR [7181748] TEST_BUG: java/lang/ThreadGroup/Suspend test fails intermittently

2013-06-13 Thread Chris Hegarty
The updated webrev looks good to me Ivan. Sorry for sending you off on the wrong track! Let me know if you need a sponsor to push this. -Chris. On 06/13/2013 11:33 AM, Ivan Gerasimov wrote: Thank you, David. I've reverted the code back, added volatile specification to the count variable. Wou

Re: RFR [7181748] TEST_BUG: java/lang/ThreadGroup/Suspend test fails intermittently

2013-06-13 Thread Ivan Gerasimov
Thank you, David. I've reverted the code back, added volatile specification to the count variable. Would you please review the webrev with this only change (comparing to webrev.0): http://cr.openjdk.java.net/~igerasim/7181748/webrev.2/ Sincerely yours, Ivan On 12.06.2013 13:49, David Holmes

Re: RFR [7181748] TEST_BUG: java/lang/ThreadGroup/Suspend test fails intermittently

2013-06-12 Thread David Holmes
On 12/06/2013 12:13 AM, Ivan Gerasimov wrote: Chris and David, thanks for review. I've updated the test so the threads use CountDownLatch to wait for each other. Now, instead of checking whether the 'second' thread has incremented a count, the 'main' thread waits for it to call countDown(). If a

Re: RFR [7181748] TEST_BUG: java/lang/ThreadGroup/Suspend test fails intermittently

2013-06-11 Thread Ivan Gerasimov
Chris and David, thanks for review. I've updated the test so the threads use CountDownLatch to wait for each other. Now, instead of checking whether the 'second' thread has incremented a count, the 'main' thread waits for it to call countDown(). If a timeout was elapsed before the call, I assum

Re: RFR [7181748] TEST_BUG: java/lang/ThreadGroup/Suspend test fails intermittently

2013-06-11 Thread Chris Hegarty
On 06/11/2013 08:08 AM, David Holmes wrote: On 11/06/2013 1:54 AM, Chris Hegarty wrote: I'm not sure I ever saw this test fail, but it does look like it has issues. I would much prefer to see a j.u.c.Latch/Phaser used to synchronize across these threads. I don't think that is possible. The ma

Re: RFR [7181748] TEST_BUG: java/lang/ThreadGroup/Suspend test fails intermittently

2013-06-11 Thread David Holmes
On 11/06/2013 1:54 AM, Chris Hegarty wrote: I'm not sure I ever saw this test fail, but it does look like it has issues. I would much prefer to see a j.u.c.Latch/Phaser used to synchronize across these threads. I don't think that is possible. The main thread wants to reset the count after the

Re: RFR [7181748] TEST_BUG: java/lang/ThreadGroup/Suspend test fails intermittently

2013-06-10 Thread Chris Hegarty
I'm not sure I ever saw this test fail, but it does look like it has issues. I would much prefer to see a j.u.c.Latch/Phaser used to synchronize across these threads. -Chris. On 10/06/2013 13:51, Ivan Gerasimov wrote: Hello everyone! The test of ThreadGroup.Suspend() was reported to fail on

RFR [7181748] TEST_BUG: java/lang/ThreadGroup/Suspend test fails intermittently

2013-06-10 Thread Ivan Gerasimov
Hello everyone! The test of ThreadGroup.Suspend() was reported to fail on rare occasions. It can happen on a busy machine that 1 second delay would not be enough for the second thread to start. Then the first thread would suspend only itself and the test would fail. Earlier, another test was up