RFR: 8330670: Obsolete ScavengeBeforeFullGC

Albert Mingkun Yang ayang at openjdk.org
Fri Apr 19 12:18:55 UTC 2024


On Fri, 19 Apr 2024 12:09:44 GMT, Stefan Karlsson <stefank at openjdk.org> wrote:

>> Obsolete a gc product flag.
>> 
>> Test: tier1-3
>
> src/hotspot/share/gc/z/zDriver.cpp line 313:
> 
>> 311:   assert(!should_clear_soft_references(cause), "Clearing soft references without pre-cleaning young gen");
>> 312: 
>> 313:   return false;
> 
> I'm not sure if this is correct. We previously returned true here if the user didn't set ScavengeBeforeFullGC, right? Maybe we need a ZGC-specific flag to allow this "precleaning" to be turned off?

`ScavengeBeforeFullGC` is true by default only for Parallel.


  if (!UseParallelGC && FLAG_IS_DEFAULT(ScavengeBeforeFullGC)) {
    FLAG_SET_DEFAULT(ScavengeBeforeFullGC, false);
  }

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

PR Review Comment: https://git.openjdk.org/jdk/pull/18861#discussion_r1572280002


More information about the hotspot-gc-dev mailing list