RFR: Consolidate oop iterators
Roman Kennke
rkennke at redhat.com
Mon Feb 6 21:15:00 UTC 2017
We do have some more oop closures that happen to be *very similar* to
our concurrent marking closures, that is the
ShenandoahInitMarkRootsClosure for marking the GC roots in init-mark,
and the ShenandoahCMKeepAliveClosure and
ShenandoahCMKeepAliveUpdateClosure which are both used during weakref-
processing to mark referents that are found to be alive.
The difference between the latter two is that one updates references,
the other not. The update-references is done non-concurrently though,
it uses simple stores instead of CASes (in contrast to the conc-mark
iterators). The init-mark-root closure does not update references at
all, but needs to resolve brooks ptrs through to to-space objects.
I replaced the bool UPDATE_REFS with an enum that lists all 4 modes (no
update-refs, resolve, simple and concurrent), moved the actual marking-
through-refs code to ShenandoahConcurrentMark::mark_through_ref() and
call that from all of the concurrent mark closures and the keep-alive
and init-mark-roots closures.
I've run both SPECjbb and SPECjvm and haven't seen any perf
regressions.
Ok?
http://cr.openjdk.java.net/~rkennke/consolidate-closures/webrev.00/
Roman
More information about the shenandoah-dev
mailing list