G1 RSet improvement ideas
Thomas Schatzl
thomas.schatzl at oracle.com
Mon Feb 3 11:56:20 UTC 2014
Hi again,
On Mon, 2014-02-03 at 10:58 +0100, Thomas Schatzl wrote:
> Hi,
>
> let me have a stab at this long mail with a few half-baked
> thoughts... ;)
>
> On Thu, 2014-01-30 at 12:33 -0500, Tony Printezis wrote:
> > Hi all,
> >
> > (5) G1 RSets: Don't use the card table during RSet scanning to reduce
> > duplication
> >
> > Currently, while scanning Remembered Sets (RSets) during a GC we use the
> > card table to mark whether a particular card has been scanned or not
> > (since the same card might appear on multiple RSets). This is bad for a
> > couple of reasons (the first one is the important one, the second one we
> > could address reasonably easily):
> >
> > - First, we have to clear the card table at the end of the GC, which
> > requires a non-trivial amount of work.
>
> Do you have numbers here? It definitely is a valid concern (with large
> heaps), but in the logs I got so far, this has not been a really big issue
> yet because the other phases are so much longer...
>
> A more coarse second-level card table (512k/1M card size?) remembering
> approximately where these marks are should already go a long way towards
> reducing the overhead?
Okay, I just saw that the card table is only cleared for regions that
contain dirty cards already.
Need to dig into the code and see how it works exactly. :)
The only remaining comment is that e.g. at 32M region size this seems to
be a rather coarse granularity.
Thomas
More information about the hotspot-gc-dev
mailing list