RFR: 8368080: G1: Unnecessary initialization of G1CMTask's mark stats table

Aleksey Shipilev shade at openjdk.org
Mon Sep 22 07:45:16 UTC 2025


On Fri, 19 Sep 2025 11:49:59 GMT, Thomas Schatzl <tschatzl at openjdk.org> wrote:

> Hi all,
> 
>   please review this tiny change that leaves out resetting the mark stat caches at startup.
> 
> This has some (somewhat tiny, depending on heap size and number of threads) positive impact on startup time.
> 
> Testing: tier1-5, gha
> 
> Thanks,
>   Thomas

Question: There is a use of `G1RegionMarkStatsCache` in `G1CMTask` (responsible for concurrent marking as well?) -- shouldn't the reset happen on that path as well? If so, and testing did not caught it, there should be some sort of assert somewhere?

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

PR Review: https://git.openjdk.org/jdk/pull/27390#pullrequestreview-3251000752


More information about the hotspot-gc-dev mailing list