[concurrency-interest] RRWL with 'bad' Thread.getId() implementations

Valentin Kovalenko valentin.male.kovalenko at gmail.com
Wed Jun 26 17:05:30 EDT 2013


Thenks!
Now I see, my code with only two threads reproduces the bug for Oracle
JDK1.6 implementation, but for JDK1.7 implementation one actually need
three threads to reproduce the bug.

>>There is special logic in place in RRWL (firstReader/firstReaderHoldCount)
>>to optimize the uncontended read lock scenario, this is why you need to
have
>>the an additional thread to push you past this logic and expose the issue
>>with cachedHoldCounter.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://cs.oswego.edu/pipermail/concurrency-interest/attachments/20130627/2b210dc1/attachment.html>


More information about the Concurrency-interest mailing list