Details
-
Bug
-
Resolution: Fixed
-
P2
-
hs14, 6u12, 6u14
-
b06
-
x86
-
solaris_10
-
Verified
Backports
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-2187039 | 7 | David Holmes | P2 | Closed | Fixed | b79 |
JDK-2189987 | 6u21 | David Holmes | P2 | Closed | Fixed | b01 |
JDK-2185849 | 6u18 | David Holmes | P2 | Closed | Fixed | b06 |
JDK-2185608 | hs16 | David Holmes | P2 | Closed | Fixed | b13 |
Description
OS = Solaris 10 (does not happen with Linux)
JDK = JDK 6.0 upd 10 and 12
Problem Description
Java threads are blocked waiting for a lock that is not held by
any threads ie. a lock that has already been released. thread is
seen waiting on this synchronizer -
- parking to wait for <0xfffffd72f0e32118> (a java.util.concurrent.lock
s.ReentrantReadWriteLock$NonfairSync)
Troubleshooting results are available to show that
the lock is not being held by any thread. See details in comments.
This hung issue is only happening on Netra x4450 but not
any other platforms such as x2200s, x4440s, x4600s, and Niagara-based systems like a 5440.
A testcase and more details are available in comments.
A similar problem was reported via the concurrency-interest mailing list and then on the core-libs dev list.
http://mail.openjdk.java.net/pipermail/core-libs-dev/2009-July/002040.html
The problem is not restricted to x4450 but shows up on 4-8way Intel systems. Same basic scenario - the application hangs with a bunch of threads all inside a LinkedBlockingQueue trying to acquire the internal ReentrantLock that nobody seems to own. Again -XX:+UseMembar avoids the problem.
I used the attached test program to reproduce the problem on an 8-way Intel machine that I have access to. However when I tried to probe deeper by using modified classes that allowed me to examine the internal lock state when the hang occurs, it ceased to occur.
Two different hangs are possible with the test program:
a) use of the application LinkedBlockingDeque
b) use of the ThreadPoolExecutors LinkedBlockingQueue
Thanks to Ariel Weisburg and Ryan Betts for reporting the problem and working to get a small reproducible test case.
Attachments
Issue Links
- backported by
-
JDK-2185608 ReentrantReadWriteLock: threads hung when there are no threads holding onto the lock (Netra x4450)
- Closed
-
JDK-2185849 ReentrantReadWriteLock: threads hung when there are no threads holding onto the lock (Netra x4450)
- Closed
-
JDK-2187039 ReentrantReadWriteLock: threads hung when there are no threads holding onto the lock (Netra x4450)
- Closed
-
JDK-2189987 ReentrantReadWriteLock: threads hung when there are no threads holding onto the lock (Netra x4450)
- Closed
- duplicates
-
JDK-6903249 array blocking queues hangs on new Intel processor (Nehalem)
- Closed
- relates to
-
JDK-6865591 [TESTBUG] closed/runtime/6471091/Test6471091.java hangs on Solaris-i586
- Resolved
-
JDK-6801020 Concurrent Semaphore release may cause some require thread not signaled
- Closed
-
JDK-7011862 java/util/concurrent utilities need to handle StackOverflowError:Class loading hang with clss21201m1
- Closed
-
JDK-6807483 java.util.concurrent.locks.Condition.await(timeout, units) hangs forever
- Closed
-
JDK-7191630 ReentrantReadWriteLock in inconsistent state
- Closed
-
JDK-8004902 correctness fixes motivated by contended locking work (6607129)
- Closed