RFR: 8262885: Shenandoah: FullGC prologue does not need to save/restore heap has_forwarded_object flag

Aleksey Shipilev shade at openjdk.java.net
Wed Mar 3 06:56:56 UTC 2021


On Tue, 2 Mar 2021 21:40:45 GMT, Zhengyu Gu <zgu at openjdk.org> wrote:

> Another trivial cleanup. FullGC prologue code does not change heap's has_forwarded_objects flag, there is no point to save/restore it.
> 
> Test:
> - [x] hotspot_gc_shenandoah

Yeah, but this code protects from some downstream code we are calling from the prologue to accidentally drop the flag. At least it should be asserted that `has_forwarded_objects` has the same value at the end of the prologue as it was at the beginning. Or better just leave this for safety?

-------------

PR: https://git.openjdk.java.net/jdk/pull/2797



More information about the hotspot-gc-dev mailing list