RFR: 8342382: Implementation of JEP G1: Improve Application Throughput with a More Efficient Write-Barrier [v11]
Thomas Schatzl
tschatzl at openjdk.org
Tue Mar 4 16:03:55 UTC 2025
On Tue, 4 Mar 2025 15:16:17 GMT, Albert Mingkun Yang <ayang at openjdk.org> wrote:
>> Thomas Schatzl has updated the pull request incrementally with one additional commit since the last revision:
>>
>> iwalulya review
>> * comments for variables tracking to-collection-set and just dirtied cards after GC/refinement
>> * predicate for determining whether the refinement has been disabled
>> * some other typos/comment improvements
>> * renamed _has_xxx_ref to _has_ref_to_xxx to be more consistent with naming
>
> src/hotspot/share/gc/g1/g1ConcurrentRefine.cpp line 356:
>
>> 354: bool do_heap_region(G1HeapRegion* r) override {
>> 355: if (!r->is_free()) {
>> 356: // Need to scan all parts of non-free regions, so reset the claim.
>
> Why is the condition "is_free"? I thought we scan only old-or-humongous regions?
We also need to clear young gen region marks because we want them to be all clean in the card table for the garbage collection (evacuation failure handling, use in next cycle).
This is maybe a bit of a waste if there are multiple refinement rounds between two gcs, but it's less expensive than in the pause wrt to latency. It's fast anyway.
> src/hotspot/share/gc/g1/g1ConcurrentRefine.hpp line 116:
>
>> 114: SwapGlobalCT, // Swap global card table.
>> 115: SwapJavaThreadsCT, // Swap java thread's card tables.
>> 116: SwapGCThreadsCT, // Swap GC thread's card tables.
>
> Do GC threads have card-table?
Hmm, I thought I changed tat already just recently with Ivan's latest requests. Will fix.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/23739#discussion_r1979742662
PR Review Comment: https://git.openjdk.org/jdk/pull/23739#discussion_r1979752692
More information about the core-libs-dev
mailing list