RFR: 8199927: Make WhiteBox more GC agnostic (original) (raw)
Per Liden per.liden at oracle.com
Thu Mar 22 09:04:42 UTC 2018
- Previous message (by thread): RFR: 8199927: Make WhiteBox more GC agnostic
- Next message (by thread): RFR: 8199927: Make WhiteBox more GC agnostic
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 03/21/2018 04:03 PM, Aleksey Shipilev wrote:
On 03/21/2018 03:50 PM, Per Liden wrote:
Updated webrev to reflect that GCSelector changed name to GCConfig in the patch for JDK-8199925.
http://cr.openjdk.java.net/~pliden/8199927/webrev.1 Looks good to me.
Thanks for reviewing!
This is a little dizzy, because I would have expected gc.isSelected() would tell me exactly what GC was being selected: isAcceptable = gc.isSupported() && (gc.isSelected() || GC.isSelectedErgonomically()); ...so it should be just: for (GC gc : GC.values()) { map.put("vm.gc." + gc.name(), "" + gc.isSelected()); }
The way VMProps works and how the properties are set up can indeed make you a little dizzy. For example, vm.gc.Parallel=true doesn't necessarily mean that ParallelGC was "selected", just that it's an "acceptable" configuration.
A test running with an explicit -XX:UseG1GC flag will get: vm.gc.Serial=false vm.gc.Parallel=false vm.gc.CMS=false vm.gc.G1=true
And a test running with no explicit GC flag (which selects G1 ergonomically), will get: vm.gc.Serial=true vm.gc.Parallel=true vm.gc.CMS=true vm.gc.G1=true
I believe your suggested cleanup would change that behavior.
cheers, Per
?
Thanks, -Aleksey
- Previous message (by thread): RFR: 8199927: Make WhiteBox more GC agnostic
- Next message (by thread): RFR: 8199927: Make WhiteBox more GC agnostic
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]