UseGCOverheadLimit for G1

Man Cao manc at
Fri Oct 12 17:47:07 UTC 2018

Sounds good. I'll take a stab at it.

Does initiating the AdaptiveSizePolicy class for G1, or create a subclass
G1AdaptiveSizePolicy sound like an acceptable high-level approach?
I know it is a non-goal to make UseAdaptiveSizePolicy work for G1, but most
logic for UseGCOverheadLimit is in the AdaptiveSizePolicy class.
This seems the approach that reuse most existing code and does not affect

A side story is that we have a Google-local patch since JDK6 that makes
UseGCOverheadLimit work properly for CMS.
UseAdaptiveSizePolicy doesn't work and is disabled by default for CMS, but
UseGCOverheadLimit depends on logic in the CMSAdaptiveSizePolicy class
(which was removed in JDK9) to properly collect major GC overhead.


On Fri, Oct 12, 2018 at 12:10 AM Thomas Schatzl <thomas.schatzl at>

> Hi Man,
> On Thu, 2018-10-11 at 14:51 -0700, Man Cao wrote:
> > Hi all,
> >
> > I noticed that UseGCOverheadLimit does not really work for G1.
> > I created an RFE:
> >
> > I also search JBS and mail archive, but didn't find any plan to
> > implement UseGCOverheadLimit for G1. Is this a desirable feature to
> > be implemented in the future?
> >
>   if it is something you need, feel free to implement. I see no
> particular reason why it shouldn't be supported.
> Thanks,
>   Thomas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the hotspot-gc-dev mailing list