GCOverheadLimit support for G1

Thomas Schatzl thomas.schatzl at oracle.com
Mon Jan 13 09:28:47 UTC 2025


Hi again,

On 13.01.25 10:24, Thomas Schatzl wrote:
> Hi Sonia,
> 
> On 10.01.25 15:15, Sonia Zaldana Calles wrote:
>> Hi folks,
>>
>>
>> Upon migration from ParallelGC to G1, we have a report that G1 is 
>> showcasing a slow death when too much time is spent in garbage 
>> collection, in contrast to ParallelGC, which would trigger an 
>> “OutOfMemoryError: GC Overhead limit exceeded”.
>>
>>
>> Note the single class reproducer below [0]. Running with java ... - 
>> Xlog:gc -Xmx4G, we can observe long pauses (~3-4 seconds on my 
>> machine), the VM attempts ~20 Full GC cycles where the last full GCs 
>> take a lot longer than the pause time goal of 200ms. Ideally, we would 
>> like the JVM to stop trying at some point early (similarly to 
>> ParallelGC) and we have not found a way to accomplish that.
>>
>>
>> We found this is likely because UseGCOverheadLimit is only supported 
>> (and enabled by default) for the ParallelGC. We came across 
>> JDK-8212084 and we were wondering if there was a particular reason 
>> this didn’t move forward? [1] Is there anything we can do to help?
>>
>>
> 
>    as most of the time, I do not think there is a particular reason this 
> work has not been completed. Just as the comments in that CR indicate, 
> that the original problem went away for them and interest has been lost.
> 
Drop the last sentence - having re-read the discussion at 
https://mail.openjdk.org/pipermail/hotspot-gc-dev/2018-October/023525.html, 
I do not think there is a particular reason why it has not been 
implemented apart from losing interest.

Thomas


More information about the hotspot-gc-dev mailing list