RE: JavaMemoryModel: Re: Java Memory Model and exceptions ?

From: Miles Sabin (msabin@interx.com)
Date: Wed Aug 22 2001 - 13:05:44 EDT


Cliff Click wrote,
> Bill Pugh wrote:
> > A related question that I would like some input on from people on
> > the list: are Errors guaranteed to be precise? What if the JVM
> > throws an InternalError or StackOverflowError? Is it required to
> > be the case that there exists some point in the original program
> > such that all writes before that point were committed and no
> > writes after that point are performed? What implementation
> > strategies do JVMs use to handle this?
>
> Sun's certainly gone to some length to make sure StackOverflowError
> appears to be thrown at some particular point. InternalErrors are
> never thrown because we don't have recoverable errors; i.e. the VM
> crashes instead. :-)

Is that right? On JSR 51 we went to some lengths to squeeze a
promise out of the Hotspot team that reads or writes of
MappedByteBuffers whose underlying mmap'd file had been truncated
out from under them would result in some (not necessarily very
precise) InternalError being thrown eventually, rather than having the
VM exit on a signal.

Have I misunderstood what's going on in this case?

Cheers,

Miles

-- 
Miles Sabin                                     InterX
Internet Systems Architect                      27 Great West Road
+44 (0)20 8817 4030                             Middx, TW8 9AS, UK
msabin@interx.com                               http://www.interx.com/

------------------------------- JavaMemoryModel mailing list - http://www.cs.umd.edu/~pugh/java/memoryModel



This archive was generated by hypermail 2b29 : Thu Oct 13 2005 - 07:00:34 EDT