RFR: Refactor/consolidate/cleanup
Roman Kennke
rkennke at redhat.com
Thu Nov 24 19:49:09 UTC 2016
We have several pieces of information duplicated, mostly between
ShenandoahHeapRegion and fast-access variants in ShenandoahHeap:
- in-collection-set
- top-at-mark-start (prev and next)
This change consolidates the code to use only the fast-access versions.
There's no reason to have both, and struggle to keep them in sync.
Swapping mark bitmap now also swaps the corresponding top-at-mark-start
pointers. Before this was done in different places and was quite a
mess.
prev- and next marking bitmap and top-at-mark-start pointers are
renamed to 'complete' and 'next', this tells a bit more about what they
are: the 'next' structures are only ever used during marking, it's the
bitmap in progress. The 'complete' structures are completed markings.
The 'next' gets swapped with 'complete' right after marking.
I removed marked_next_object_iterate(). We should only ever use
complete marking bitmaps for iteration. This was an exception during
mark-compact, because we did not swap the bitmaps after marking.
Also removed a bunch of unused and obsolete code.
Tested by jtreg and SPECjvm2008
http://cr.openjdk.java.net/~rkennke/bigrefactor/webrev.00/
Ok?
Roman
More information about the shenandoah-dev
mailing list