RFR: bug: Timely Reducing Unused Committed Memory
Per Liden
per.liden at oracle.com
Fri Sep 7 08:20:41 UTC 2018
Hi,
On 09/06/2018 05:51 PM, Thomas Schatzl wrote:
[...]
> - naming of the flags: I think at least GCFrequency is too generic, and
> should be in ms too.
I'm also thinking we need to think through the flags names a bit. First
question is if these should be prefixed with G1, or if we think they are
general enough to be applicable to the other GC (or at least some of
them). I'm leaning towards having a G1 prefix.
The name "GCFrequency" suggests that the unit is Hz, but it's seconds,
so something like "Interval" would probably be better. I'm also thinking
that "UseFullGCForIdleCompaction" could be "IdleGCInvokesConcurrent" to
better map with the exiting "ExplicitGCInvokesConcurrent".
Here's a naming suggestion, just to kick of the discussion.
GCFrequency -> G1IdleGCInterval
UseFullGCForIdleCompaction -> G1IdleGCInvokesConcurrent
MaxLoadGC -> G1IdleGCMaxLoad
MaxOverCommittedMem -> G1IdleGCMaxUnused
MinCommittedMem -> G1IdleGCMinCapacity
Btw, the comments attached to these if-statements are not reflecting
what they are actually doing.
+ // Check if the used memory is above a threshold.
+ if ((MinCommittedMem > 0) &&
+ (Universe::heap()->capacity() < MinCommittedMem)) {
+ return false;
+ }
s/used memory/capacity/
+ // Check if the difference between max capacity and current capacity is
+ // above a threshold.
+ if ((MaxOverCommittedMem > 0) &&
+ (Universe::heap()->capacity() - Universe::heap()->used() <
MaxOverCommittedMem)) {
+ return false;
+ }
s/max capacity and current capacity/capacity and used/
cheers,
Per
More information about the hotspot-gc-dev
mailing list