harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Xiao-Feng Li" <xiaofeng...@gmail.com>
Subject Re: [drlvm][jitrino]-about exception handling
Date Mon, 06 Aug 2007 11:33:08 GMT
On 8/6/07, 史成荣 <icyrong@gmail.com> wrote:
> 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."

Chengrong, no matter the releasing op is conducted by JVM
automatically or in an explicitly created catch block, the idea is the
same: to release the lock. It's only implementation difference.

> 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.

I am sure there is some description on it. Please check exception chapter.


> Thanks,
> Chengrong

View raw message