RFR: 8343782: G1: Use one G1CardSet instance for multiple old gen regions [v10]

Albert Mingkun Yang ayang at openjdk.org
Mon Dec 23 21:05:43 UTC 2024


On Mon, 23 Dec 2024 11:08:57 GMT, Ivan Walulya <iwalulya at openjdk.org> wrote:

>> src/hotspot/share/gc/g1/g1ConcurrentMark.cpp line 3172:
>> 
>>> 3170:                           size_t(0), young_only_cset_group->card_set()->mem_size());
>>> 3171: 
>>> 3172:   for (G1CSetCandidateGroup* group : g1h->policy()->candidates()->from_marking_groups()) {
>> 
>> This would skip retained groups, right?  Is that intentional?
>
> Yes, retained regions are in "single region" groups, so all details should be added to the log when we call `do_heap_region`

I see; however, this would print the same gc_eff twice if young-gen contains a single region, right? Since this method is about cset-groups, I think it's more natural to visit all groups (regardless their size) here. With this PR, there is no gc_eff associated with individual region, `do_heap_region` can just skip gc_eff.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/22015#discussion_r1896120738


More information about the hotspot-gc-dev mailing list