Integrated: 8254912: ZGC: Change ZCollectionInterval type to double

Stefan Karlsson stefank at openjdk.java.net
Mon Oct 19 07:27:11 UTC 2020


On Fri, 16 Oct 2020 14:45:20 GMT, Stefan Karlsson <stefank at openjdk.org> wrote:

> ZCollectionInterval is used to trigger GCs within certain time intervals. The flag specifies how many seconds to wait,
> and the type is uint. That means that the user can only specify the interval as discrete seconds. This is probably fine
> in most cases, but during stress testing it's often beneficial to be able to set a lower value. I propose that we
> change the type to double, so that one can use, say, -XX:ZCollectionInterval=0.5 to trigger GC every half second.  Note
> 1: that there's an effective lower-bound determined by how often the code checks if it's time to start a GC. That timer
> is today set to 100ms.  Note 2: The change is backwards-compatible, so specifying the flag as an integer still
> works: -XX:ZCollectionInterval=5

This pull request has now been integrated.

Changeset: 8edc2f05
Author:    Stefan Karlsson <stefank at openjdk.org>
URL:       https://git.openjdk.java.net/jdk/commit/8edc2f05
Stats:     3 lines in 2 files changed: 0 ins; 0 del; 3 mod

8254912: ZGC: Change ZCollectionInterval type to double

Reviewed-by: pliden, ayang

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

PR: https://git.openjdk.java.net/jdk/pull/702



More information about the hotspot-gc-dev mailing list