RFR: 8276098: Do precise BOT updates in G1 evacuation phase [v3]

Yude Lin duke at openjdk.java.net
Tue Nov 9 09:21:43 UTC 2021

On Tue, 9 Nov 2021 07:39:03 GMT, Yude Lin <duke at openjdk.java.net> wrote:

> I was thinking that `forward_to_block_containing_addr_slow` should never be reached now, since all entries are now precise. However, when I add ShouldNotReachHere before `forward_to_block_containing_addr_slow` in `G1BlockOffsetTablePart::forward_to_block_containing_addr` I noticed that there are some exceptional cases and in these cases `n` always equals to `addr`. Not sure if this is expected? I'll continue looking, just want to report this very quickly.

Okay, it's actually not relevant to this patch. ``G1ScanHRForRegionClosure::do_claimed_block`` has made an unaligned request to BOT because of ``_scanned_to``. That is, ``_scanned_to`` is not aligned on card boundary. And this causes a slow path. I think there might be an easy way to prevent slow path, e.g., make a special case for unaligned mr.start() in ``HeapRegion::oops_on_memregion_seq_iterate_careful``. But that might be another topic.


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

More information about the hotspot-gc-dev mailing list