Re: JavaMemoryModel: Array

From: Clifford Click (cliff.click@sun.com)
Date: Tue Dec 11 2001 - 19:20:51 EST


Jeremy Manson wrote:
>
> Cliff Click wrote:
>
> >
> > Jean-Philippe Lesot wrote:
> >
> > > I need a way to prevent
> > > such optimizations without using method call but using classic array access.
> > >
> > > Is it possible in the present Java Memory Model? And in your proposition?
> >
> >
> > Insert a lock/unlock between the array refs.
> >
>
> I thought we had decided that thread-local and other "useless"
> synchronization could be eliminated. No?

Oops, sorry, my mistake. lock/unlock is only sufficient on
the current version of HotSpot. Certainly some future
optimizations might invalidate that.

Cliff

--
Cliff Click                  Compiler Designer and Researcher
cliffc at acm.org            Java Software
(408) 276-7046               MS USCA14-102
-------------------------------
JavaMemoryModel mailing list - http://www.cs.umd.edu/~pugh/java/memoryModel



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