But it is said in Mark Stoodley's paper: Automatically Reducing Repetitive Synchronization with a Just-in-Time Compiler for Java(cgo'05) that "The exception handling infrastructure in IBM's JVM is already designed to track objects as they are locked and unlocked. It automatically unlock any locked objects when the exception occurs before any exception handler is executed or before the frame is deleted if there is no handler for the exception in the frame's method. This mechanism is orthogonal to synchronization elimination. In a JVM without such a mechanism, new catch blocks must be created to explicitly unlock the object if an exception occurs." And I had a look at chaprer 8 and 7.12 of JVM spec, didn't find any description about the releasing of the lock(s) when the exception is thrown.
Thanks, Chengrong
