RFR(S): 8032011 nsk/stress/jck60/jck60022 crashes in src\share\vm\runtime\synchronizer.cpp:239 (original) (raw)

Vladimir Kozlov vladimir.kozlov at oracle.com
Mon Feb 10 16:15:58 PST 2014


Good.

Vladimir

On 2/10/14 3:07 PM, Roland Westrelin wrote:

With the code sketched below:

m1() { synchronized(monitor) { // eliminated by c2 m2(); // deoptimized here } } m2() { synchronized(monitor) { // not eliminated but biased to current thread // uncommon trap } } 1) In m1(), the monitor is eliminated 2) m2() calls m1(), the monitor is acquired biased to current thread 3) uncommon trap happens in m2() which causes the bias on monitor to be revoked. The monitor is erroneoulsy locked using a basic lock in m1() 4) execution returns to m1() which is mark for deoptimization. Deoptimization tries to relock the eliminated monitor but find it already locked by current thread which should be impossible. Skipping all eliminated monitors in getorcomputemonitorinfo() makes sure revokebias does not lock the monitor using a basic lock in the wrong frame. http://cr.openjdk.java.net/~roland/8032011/webrev.00/ Roland.



More information about the hotspot-compiler-dev mailing list