Ramki wrote:
> Programmers steeped in the posix tradition
> often tend to think of mutex_lock/_unlock
> as memory barriers of sorts. That might have
> been one source/rationale for the restriction below?
And programmers used to anything bar an aggressively optimisation JIT/VM
won't expect their code to get reordered much at all :-)
I still have concerns over how sync block merging can be specified such that
the "fairness" issues Bill mentioned can be dealt with. The classic example
is:
readlock.acquire();
// access data structure
readlock.release();
Both acquire and release are "sync blocks" but I certainly don't want them
to be merged.
David Holmes
-------------------------------
JavaMemoryModel mailing list - http://www.cs.umd.edu/~pugh/java/memoryModel
This archive was generated by hypermail 2b29 : Thu Oct 13 2005 - 07:00:39 EDT