Re: [ping][ping] Re: RFR 8034168: ThreadMXBean/Locks.java failed, blocked on wrong object

2014-03-11 Thread David Holmes
If it cures the testing failures I have no problem with it. Thanks, David On 11/03/2014 6:57 PM, Jaroslav Bachorik wrote: On 25.2.2014 14:45, Jaroslav Bachorik wrote: On 20.2.2014 18:04, Martin Buchholz wrote: I think David is too pessimistic about Thread.yield being ineffective on Java SE im

[ping][ping] Re: RFR 8034168: ThreadMXBean/Locks.java failed, blocked on wrong object

2014-03-11 Thread Jaroslav Bachorik
On 25.2.2014 14:45, Jaroslav Bachorik wrote: On 20.2.2014 18:04, Martin Buchholz wrote: I think David is too pessimistic about Thread.yield being ineffective on Java SE implementations (OTOH David is a Java Embedded expert). In practice an implementation that never thread switched out of a yiel

[ping] Re: RFR 8034168: ThreadMXBean/Locks.java failed, blocked on wrong object

2014-03-03 Thread Jaroslav Bachorik
On 25.2.2014 14:45, Jaroslav Bachorik wrote: On 20.2.2014 18:04, Martin Buchholz wrote: I think David is too pessimistic about Thread.yield being ineffective on Java SE implementations (OTOH David is a Java Embedded expert). In practice an implementation that never thread switched out of a yiel

Re: RFR 8034168: ThreadMXBean/Locks.java failed, blocked on wrong object

2014-02-25 Thread Jaroslav Bachorik
On 20.2.2014 18:04, Martin Buchholz wrote: I think David is too pessimistic about Thread.yield being ineffective on Java SE implementations (OTOH David is a Java Embedded expert). In practice an implementation that never thread switched out of a yield() loop would not pass the tck. As for theor

Re: RFR 8034168: ThreadMXBean/Locks.java failed, blocked on wrong object

2014-02-22 Thread Erik Gahlin
Looks good. /Erik Jaroslav Bachorik skrev 2/18/14 5:22 PM: Please, review the following test change. Issue : https://bugs.openjdk.java.net/browse/JDK-8034168 Webrev: http://cr.openjdk.java.net/~jbachorik/8034168/webrev.00 The test fails because of falsely evaluating the thread being parked a

Re: RFR 8034168: ThreadMXBean/Locks.java failed, blocked on wrong object

2014-02-20 Thread Jaroslav Bachorik
This was discussed when reviewing ThreadMXBean/SynchronizationStatistics.java Regarding a busy wait checking the thread states and issuing Thread.yield() now and then David Holmes wrote: "Not elegant and not completely reliable either. Probably adequate on a multi-core system but single-core a

Re: RFR 8034168: ThreadMXBean/Locks.java failed, blocked on wrong object

2014-02-18 Thread Jaroslav Bachorik
On 18.2.2014 18:06, Martin Buchholz wrote: Not checking any details, but tests that want to wait for a particular thread state are a good reason to use volatile boolean flag; ... while (!flag) Thread.yield(); I prefer calling Thread.yield to sleeping in this special case, in part because I don'

RFR 8034168: ThreadMXBean/Locks.java failed, blocked on wrong object

2014-02-18 Thread Jaroslav Bachorik
Please, review the following test change. Issue : https://bugs.openjdk.java.net/browse/JDK-8034168 Webrev: http://cr.openjdk.java.net/~jbachorik/8034168/webrev.00 The test fails because of falsely evaluating the thread being parked as actually waiting on a monitor. This is because there is no d