[rvm-research] remembered sets processing for a three-generational immix collector
Shoaib Akram <[email protected]> Sat, 4 Mar 2017 22:12:33 +0100
| Newsgroups | gmane.comp.java.jikes.rvm.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi All,
I am trying to extend the generational immix collector to three generations: a copying nursery with bump pointer allocation, an immix space for nursery survivors, and an immix mature space. The survivors space is contiguous in memory placed next to the nursery space. For this to work, I need to remember the pointer updates from the mature to the survivors space. Below is the fast path when an object reference is updated outside the nursery and the survivor spaces. In the prepare phase of the collection of the survivors space, I flush the entries in the remembered sets stored locally by the mutator in a write buffer. Now here is the problem. During the release phase, the isFlushed() test on the local write buffer of the mutator fails! This means that new entries are being added to the write
buffer during the tracing procedure. How is it possible that the mutator executes the barrier code during the tracing procedure and new entries starts to accrue in the write buffer? Am I doing something wrong in the fastPath or elsewhere? Should I provide more details? Any thought are welcome.
@Inline
private void fastPath(ObjectReference src, Address slot, ObjectReference tgt, int mode) {
if (!Gen.inNursery(slot) && Gen.inNursery(tgt)) {
remset.insert(slot);
}
if (!Gen.inSurvivors(slot) && !Gen.inNursery(slot) && Gen.inSurvivors(tgt)) {
remsetSurvivors.insert(slot);
}
}
@Inline
static boolean inNursery(Address addr) {
if (USE_DISCONTIGUOUS_NURSERY)
return Map.getDescriptorForAddress(addr) == NURSERY;
else
return addr.GE(NURSERY_START);
}
@Inline
static boolean inSurvivors(Address addr) {
if (USE_DISCONTIGUOUS_SURVIVORS)
return Map.getDescriptorForAddress(addr) == SURVIVORS;
else
return (addr.GE(SURVIVORS_START) && addr.LT(NURSERY_START));
}
Regards,
Shoaib.
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot