[jmm-dev] Non-core-model issues status

Brian Goetz brian.goetz at oracle.com
Sun Aug 31 15:00:36 UTC 2014

> 1. We will spec (outermost) constructors to perform release on exit.
> The spec will not otherwise include specs on final fields, although
> there should be JLS wording to explain consequences; i.e., as one case
> of reads of fields via a reference read for the first time by a thread
> being dependent on that read.  We don't expect to explicitly support
> any further analogs of C++/C11 consume mode (which this may be seen as
> a special case of).

Just a reminder that, with value types coming down the road, we should have a story for if and when release is required on value “constructors” (still searching for the best term for these.)  Gut says: for values that have been declared non-tearable (“volatile”) yes, otherwise no?  

> 2. We introduce and spec a reachabilityFence(Object x) method, and add
> wording about it in JLS sec 12.6. Further suggestions for doing more
> are still welcome. (Also, the method name is still up for grabs.
> Except that the name "keepAlive" is known to be too confusing
> to consider.)

Pardon the bike shed… if the goal here is to communicate liveness info to the GC, then perhaps considering a new form of Reference is the right vehicle, since that’s currently the primary means by which applications can pass notes to the GC after gym class...

More information about the jmm-dev mailing list