G1, Remembered Sets & Refinement

Thomas Schatzl thomas.schatzl at oracle.com
Tue May 12 09:05:28 UTC 2015


Hi all,

On Tue, 2015-05-12 at 10:06 +0200, Thomas Schatzl wrote:
> Hi,
> 
> On Mon, 2015-05-11 at 11:46 -0700, Yu Zhang wrote:
> > Simon,
> > 
> > I will try to answer your questions.  
> > Thanks,
> > Jenny
> > On 5/8/2015 8:11 AM, Simone Bordet wrote:
> > 
> > > Hi,
> > > 
> > > I would like to ask some clarification about remembered sets (RS),
> > > buffers and refinement in G1.
> > > 
> > > My understanding is that G1 installs a write barrier to record old to
> > > young pointers.
> 
> Actually all inter-region pointers, where old->young are special cases.

  just to clear up any misunderstandings: the barrier is installed for
all writes (except ones that the compiler can prove to be uninteresting
as below, I think only guaranteed NULL-writes).

Summarizing that, G1 is interested in any old->whatever references that

- are non-NULL
- cross a region
- originate from old

(in that order btw)

For refinement, the corresponding card also needs to be non-dirty to be
enqueued, otherwise it knows that the card is already somewhere in some
queue and will eventually be looked at anyway.

Thanks,
  Thomas



More information about the hotspot-gc-use mailing list