RFR: 8336098: G1: Refactor G1RebuildRSAndScrubTask
Thomas Schatzl
tschatzl at openjdk.org
Fri Jul 19 08:31:38 UTC 2024
On Wed, 10 Jul 2024 13:26:31 GMT, Albert Mingkun Yang <ayang at openjdk.org> wrote:
> Small refactoring to consolidate the early-return logic during scan-and-rebuild.
>
> Test: tie1-3
Did you do cursory performance measurements as this change uses the chunked version of scanning for every object now? We intentionally do not do that in pauses (i.e. use the `oop_oop_iterate(, MemRegion)` code), and the reason for this split here is the same.
I.e. this has been done intentionally, not just to complicate code. Scrubbing/rebuild performance is on the critical path to reclaim memory.
I also do not really like the inlining in `scan_and_scrub_region` - the compiler will do it for us and it makes the method a lot larger which is something you noticed given the additional comments and the extra scopes. I would (slightly) prefer if that were reverted, but I do not mind that.
-------------
PR Review: https://git.openjdk.org/jdk/pull/20114#pullrequestreview-2187675664
More information about the hotspot-gc-dev
mailing list