RFR: 8338440: Parallel: Improve fragmentation mitigation in Full GC [v4]
Ivan Walulya
iwalulya at openjdk.org
Mon Aug 26 15:32:05 UTC 2024
On Fri, 23 Aug 2024 13:32:18 GMT, Albert Mingkun Yang <ayang at openjdk.org> wrote:
>> Extend `SplitInfo` to support more fine-grained splitting to mitigate the fragmentation issue during full GC. Added comments and diagrams in the process.
>>
>> For easier review, it's best to start with `SplitInfo` and then proceed to see how it is constructed in `summarize_split_space` and consumed in `first_src_addr`. The accompanying diagrams should help create a clear mental image.
>>
>> With this patch, the exec time of `runtime/ClassInitErrors/TestOutOfMemoryDuringInit.java` using Parallel drops from ~30s to ~8s, the same as other GCs, and gc-log shows similar number of GC cycles as well.
>>
>> Test: tier1-8, systemgc micro bm, CacheStress, dacapo, specjbb2005, specjvm2008
>
> Albert Mingkun Yang has updated the pull request incrementally with one additional commit since the last revision:
>
> review
Changes requested by iwalulya (Reviewer).
src/hotspot/share/gc/parallel/psParallelCompact.cpp line 129:
> 127: ParallelCompactData::RegionData::dc_completed = 0xcU << dc_shift;
> 128:
> 129: bool ParallelCompactData::RegionData::is_clear() {
Do we call this anywhere outside #ifdef ASSERT?
src/hotspot/share/gc/parallel/psParallelCompact.cpp line 391:
> 389: assert(cur_addr < region_end, "inv");
> 390: cur_addr = PSParallelCompact::mark_bitmap()->find_obj_beg(cur_addr, region_end);
> 391: if (cur_addr >= region_end) {
Shouldn't this be changed to an assert?
Given the:
`// There must be an overflowing obj in this region`
`ShouldNotReachHere();`
if the `break` is executed.
-------------
PR Review: https://git.openjdk.org/jdk/pull/20590#pullrequestreview-2260943971
PR Review Comment: https://git.openjdk.org/jdk/pull/20590#discussion_r1731418102
PR Review Comment: https://git.openjdk.org/jdk/pull/20590#discussion_r1731399930
More information about the hotspot-gc-dev
mailing list