8231489: GC watermark_0_1 failed due to "metaspace.gc.Fault: GC has happened too rare"
Reviewed-by: tschatzl, sjohanss
This commit is contained in:
parent
8fe60f46d7
commit
9e17946ab2
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2013, 2018, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2013, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -42,8 +42,6 @@ import vm.share.VMRuntimeEnvUtils;
|
||||
* Test verifies that MinMetaspaceFreeRatio/MaxMetaspaceFreeRatio settings
|
||||
* affect the frequency of GC. (High-water mark)
|
||||
*
|
||||
* Note: The test doesn't check the GC count if CMS is used.
|
||||
*
|
||||
* Quoting: Java SE 8 HotSpot[tm] Virtual Machine Garbage Collection Tuning
|
||||
* <pre>
|
||||
* Class metadata is deallocated when the corresponding Java class is unloaded.
|
||||
@ -175,11 +173,6 @@ public class HighWaterMarkTest extends FirstGCTest {
|
||||
throw new Fault("Committed amount hasn't achieved " + bytes2k(committedLevel));
|
||||
}
|
||||
|
||||
if (VMRuntimeEnvUtils.isVMOptionEnabled("UseConcMarkSweepGC")) {
|
||||
System.out.println("ConcMarkSweep is used, cannot count GC");
|
||||
return;
|
||||
}
|
||||
|
||||
int gcCount = getMetaspaceGCCount();
|
||||
if (gcCount < 0) {
|
||||
// perhpas, it's better to silently pass here... Let's see.
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2017, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,6 +29,11 @@
|
||||
* @summary converted from VM Testbase metaspace/gc/watermark_0_1.
|
||||
* VM Testbase keywords: [nonconcurrent, no_cds]
|
||||
*
|
||||
* @comment Don't run test in configurations where we can't reliably count number of metaspace triggered GCs
|
||||
* @requires vm.gc != null | !vm.opt.final.ClassUnloadingWithConcurrentMark
|
||||
* @requires vm.gc != "G1" | !vm.opt.final.ClassUnloadingWithConcurrentMark
|
||||
* @requires vm.gc != "ConcMarkSweep"
|
||||
* @requires vm.gc != "Z"
|
||||
* @library /vmTestbase /test/lib
|
||||
* @run driver jdk.test.lib.FileInstaller . .
|
||||
* @run main/othervm
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2017, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,6 +29,11 @@
|
||||
* @summary converted from VM Testbase metaspace/gc/watermark_10_20.
|
||||
* VM Testbase keywords: [nonconcurrent, no_cds]
|
||||
*
|
||||
* @comment Don't run test in configurations where we can't reliably count number of metaspace triggered GCs
|
||||
* @requires vm.gc != null | !vm.opt.final.ClassUnloadingWithConcurrentMark
|
||||
* @requires vm.gc != "G1" | !vm.opt.final.ClassUnloadingWithConcurrentMark
|
||||
* @requires vm.gc != "ConcMarkSweep"
|
||||
* @requires vm.gc != "Z"
|
||||
* @library /vmTestbase /test/lib
|
||||
* @run driver jdk.test.lib.FileInstaller . .
|
||||
* @run main/othervm
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2017, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,6 +29,11 @@
|
||||
* @summary converted from VM Testbase metaspace/gc/watermark_70_80.
|
||||
* VM Testbase keywords: [nonconcurrent, no_cds]
|
||||
*
|
||||
* @comment Don't run test in configurations where we can't reliably count number of metaspace triggered GCs
|
||||
* @requires vm.gc != null | !vm.opt.final.ClassUnloadingWithConcurrentMark
|
||||
* @requires vm.gc != "G1" | !vm.opt.final.ClassUnloadingWithConcurrentMark
|
||||
* @requires vm.gc != "ConcMarkSweep"
|
||||
* @requires vm.gc != "Z"
|
||||
* @library /vmTestbase /test/lib
|
||||
* @run driver jdk.test.lib.FileInstaller . .
|
||||
* @run main/othervm
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2017, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -29,6 +29,11 @@
|
||||
* @summary converted from VM Testbase metaspace/gc/watermark_99_100.
|
||||
* VM Testbase keywords: [nonconcurrent, no_cds]
|
||||
*
|
||||
* @comment Don't run test in configurations where we can't reliably count number of metaspace triggered GCs
|
||||
* @requires vm.gc != null | !vm.opt.final.ClassUnloadingWithConcurrentMark
|
||||
* @requires vm.gc != "G1" | !vm.opt.final.ClassUnloadingWithConcurrentMark
|
||||
* @requires vm.gc != "ConcMarkSweep"
|
||||
* @requires vm.gc != "Z"
|
||||
* @library /vmTestbase /test/lib
|
||||
* @run driver jdk.test.lib.FileInstaller . .
|
||||
* @run main/othervm
|
||||
|
@ -305,6 +305,7 @@ public class VMProps implements Callable<Map<String, String>> {
|
||||
*/
|
||||
protected void vmOptFinalFlags(SafeMap map) {
|
||||
vmOptFinalFlag(map, "ClassUnloading");
|
||||
vmOptFinalFlag(map, "ClassUnloadingWithConcurrentMark");
|
||||
vmOptFinalFlag(map, "UseCompressedOops");
|
||||
vmOptFinalFlag(map, "EnableJVMCI");
|
||||
vmOptFinalFlag(map, "EliminateAllocations");
|
||||
|
Loading…
Reference in New Issue
Block a user