RFR: 8212656: Clean up heap filler insertion

Roman Kennke rkennke at redhat.com
Thu Oct 18 13:57:57 UTC 2018


Hi Per,

I'll try to weave that into Shenandoah and see how that goes :-)

One thing that I don't see how it could work is how we could do extra
initialization for the fwd ptr? We can currently do it by overriding
fill_with_dummy_object(..) like this:

void ShenandoahHeap::fill_with_dummy_object(HeapWord* start, HeapWord*
end, bool zap) {
  HeapWord* obj = post_allocation_setup(start); // Bumps start by 1 word
  CollectedHeap::fill_with_object(obj, end);
}

This seems to have gone with your patch.

Roman

> While reviewing JDK-8211955, I suggested that the filler insertion code
> in CollectedHeap should be broken out into a Fill class (to match the
> somewhat related Copy class we already have). The filler insertion code
> doesn't have to live in the already crowded CollectedHeap class, as it's
> basically just a bunch of utility functions (just like the functions in
> the Copy class).
> 
> With this patch CollectedHeap calls Fill::initialize() in it's
> constructor. This will set up the default behavior. Collectors with
> special needs (G1, ZGC and Shenandoah) can then call one or more of the
> Fill::set_*() functions to adjust filling behavior.
> 
> Bug: https://bugs.openjdk.java.net/browse/JDK-8212656
> Webrev: http://cr.openjdk.java.net/~pliden/8212656/webrev.0
> 
> Testing: Passed tier{3,5,6} on all Oracle supported platforms, running
> additional tiers right now.
> 
> /Per

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <http://mail.openjdk.java.net/pipermail/hotspot-gc-dev/attachments/20181018/30fbe894/signature.asc>


More information about the hotspot-gc-dev mailing list