RFR: 8351405: G1: Collection set early pruning causes suboptimal region selection [v3]

Ivan Walulya iwalulya at openjdk.org
Mon Mar 24 14:50:12 UTC 2025


On Mon, 24 Mar 2025 14:44:28 GMT, Albert Mingkun Yang <ayang at openjdk.org> wrote:

>> Ivan Walulya has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains eight additional commits since the last revision:
>> 
>>  - Albert Review
>>  - Merge remote-tracking branch 'upstream/master' into ReviseRegionSelection
>>  - Thomas Review
>>  - remove double prune
>>  - save
>>  - revise region selection
>>  - save
>>  - init
>
> src/hotspot/share/gc/g1/g1CollectionSetCandidates.cpp line 151:
> 
>> 149:   G1Policy* p = G1CollectedHeap::heap()->policy();
>> 150:   size_t gc_efficiency1 = p->predict_gc_efficiency(ci1->_r);
>> 151:   size_t gc_efficiency2 = p->predict_gc_efficiency(ci2->_r);
> 
> Why converting `double` to `size_t`? Is it intentional that all `0.x` becomes 0 and are considered equal?

Missed the conversion. Let me fix it.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/24076#discussion_r2010333249


More information about the hotspot-gc-dev mailing list