RFR: 8325553: Parallel: Use per-marker cache for marking stats during Full GC
Stefan Johansson
sjohanss at openjdk.org
Mon Feb 12 14:21:55 UTC 2024
On Fri, 9 Feb 2024 12:06:04 GMT, Albert Mingkun Yang <ayang at openjdk.org> wrote:
> Add cache to avoid too much contentious writes to global marking stats.
>
> Test: tier1-6; using the attached bm, ~30% reduction in pause-time is observed. Only marginal improvement (probably just noise) is observed in BigRamTester.
I think this looks good, one comment/question about the code below. Also, have you tried the new SystemGC tests and with this change to test some more cases?
src/hotspot/share/gc/parallel/psCompactionManager.hpp line 169:
> 167: const size_t end_offset = data.region_offset(addr + live_words - 1);
> 168: data.region(end_region_id)->set_partial_obj_size(end_offset + 1);
> 169: data.region(end_region_id)->set_partial_obj_addr(addr);
I assume most of the benefit comes from having the cache when the whole object is in a single region. To avoid duplicating the logic around what to do when an object spans multiple regions we could just bail and call `add_object(...)` here:
Suggestion:
data.add_object(obj, live_words);
What do you think about that? Or will this remove a big part of the improvement?
-------------
PR Review: https://git.openjdk.org/jdk/pull/17788#pullrequestreview-1875342768
PR Review Comment: https://git.openjdk.org/jdk/pull/17788#discussion_r1486244683
More information about the hotspot-gc-dev
mailing list