RFR: 6815130 intermittent ThreadMXBean/Locks.java failure

Daniel Fuchs daniel.fuchs at oracle.com
Tue Sep 3 05:10:57 PDT 2013


Hi Jaroslav,

Have you considered replacing the ThreadExecutionSynchronizer with
a plain (and more reliable) CyclicBarrier or Phaser object?

<http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/CyclicBarrier.html>
<http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/Phaser.html>

best regards

-- daniel

On 9/3/13 1:15 PM, Jaroslav Bachorik wrote:
> Please, review the following patch of the intermittently failing test:
> http://cr.openjdk.java.net/~jbachorik/6815130/webrev.01
>
> Issue: https://bugs.openjdk.java.net/browse/JDK-6815130
>
>
> Sometimes the ThreadExecutionSynchronizer class failes to achieve the
> desired synchronization (due to possible data races when evaluating and
> setting the "waiting" variable) leading to test failures.
>
> The patch fixes the possibility of data race. Also the Locks class is
> tidied up a bit.
>
> Thanks,
>
> -JB-
>



More information about the serviceability-dev mailing list