changeset 10838:35cb720769c5

8152989: serviceability/tmtools/jstat/GcCauseTest02.java fails with OOME Reviewed-by: dsamersoff, sjohanss, dfazunen
author pliden
date Fri, 08 Apr 2016 08:51:45 +0200
parents fb0e13a7eb35
children 0dc4e30985d4
files test/serviceability/tmtools/jstat/GcCapacityTest.java test/serviceability/tmtools/jstat/GcCauseTest01.java test/serviceability/tmtools/jstat/GcCauseTest02.java test/serviceability/tmtools/jstat/GcCauseTest03.java test/serviceability/tmtools/jstat/GcNewTest.java test/serviceability/tmtools/jstat/GcTest01.java test/serviceability/tmtools/jstat/GcTest02.java
diffstat 7 files changed, 12 insertions(+), 18 deletions(-) [+]
line wrap: on
line diff
--- a/test/serviceability/tmtools/jstat/GcCapacityTest.java	Thu Apr 07 15:34:21 2016 -0700
+++ b/test/serviceability/tmtools/jstat/GcCapacityTest.java	Fri Apr 08 08:51:45 2016 +0200
@@ -27,13 +27,13 @@
  * @test
  * @summary Test checks the consistency of the output
  * displayed with jstat -gccapacity.
- * @ignore 8149778
  * @library /test/lib/share/classes
  * @library ../share
  * @requires vm.opt.ExplicitGCInvokesConcurrent != true
  * @build common.*
  * @build utils.*
- * @run main/othervm -XX:+UsePerfData GcCapacityTest
+ * @ignore 8149778
+ * @run main/othervm -XX:+UsePerfData -Xmx128M GcCapacityTest
  */
 public class GcCapacityTest {
 
--- a/test/serviceability/tmtools/jstat/GcCauseTest01.java	Thu Apr 07 15:34:21 2016 -0700
+++ b/test/serviceability/tmtools/jstat/GcCauseTest01.java	Fri Apr 08 08:51:45 2016 +0200
@@ -34,7 +34,7 @@
  * @build common.*
  * @build utils.*
  *
- * @run main/othervm -XX:+UsePerfData GcCauseTest01
+ * @run main/othervm -XX:+UsePerfData -Xmx128M GcCauseTest01
  */
 import utils.*;
 
--- a/test/serviceability/tmtools/jstat/GcCauseTest02.java	Thu Apr 07 15:34:21 2016 -0700
+++ b/test/serviceability/tmtools/jstat/GcCauseTest02.java	Fri Apr 08 08:51:45 2016 +0200
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2016, 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
@@ -32,7 +32,7 @@
  * @build common.*
  * @build utils.*
  *
- * @run main/othervm  -XX:+UsePerfData -Xms128M -XX:MaxMetaspaceSize=128M GcCauseTest02
+ * @run main/othervm -XX:+UsePerfData -Xmx128M -XX:MaxMetaspaceSize=128M GcCauseTest02
  */
 import utils.*;
 
--- a/test/serviceability/tmtools/jstat/GcCauseTest03.java	Thu Apr 07 15:34:21 2016 -0700
+++ b/test/serviceability/tmtools/jstat/GcCauseTest03.java	Fri Apr 08 08:51:45 2016 +0200
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2016, 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
@@ -32,7 +32,7 @@
  * @build common.*
  * @build utils.*
  *
- * @run main/othervm  -XX:+UsePerfData -Xms128M -XX:MaxMetaspaceSize=128M GcCauseTest03
+ * @run main/othervm -XX:+UsePerfData -Xmx128M -XX:MaxMetaspaceSize=128M GcCauseTest03
  */
 import utils.*;
 
--- a/test/serviceability/tmtools/jstat/GcNewTest.java	Thu Apr 07 15:34:21 2016 -0700
+++ b/test/serviceability/tmtools/jstat/GcNewTest.java	Fri Apr 08 08:51:45 2016 +0200
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2016, 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
@@ -33,7 +33,7 @@
  * @library ../share
  * @build common.*
  * @build utils.*
- * @run main/othervm -XX:+UsePerfData GcNewTest
+ * @run main/othervm -XX:+UsePerfData -Xmx128M GcNewTest
  */
 
 public class GcNewTest {
--- a/test/serviceability/tmtools/jstat/GcTest01.java	Thu Apr 07 15:34:21 2016 -0700
+++ b/test/serviceability/tmtools/jstat/GcTest01.java	Fri Apr 08 08:51:45 2016 +0200
@@ -37,7 +37,7 @@
  * @build common.*
  * @build utils.*
  *
- * @run main/othervm -XX:+UsePerfData GcTest01
+ * @run main/othervm -XX:+UsePerfData -Xmx128M GcTest01
  */
 import utils.*;
 
--- a/test/serviceability/tmtools/jstat/GcTest02.java	Thu Apr 07 15:34:21 2016 -0700
+++ b/test/serviceability/tmtools/jstat/GcTest02.java	Fri Apr 08 08:51:45 2016 +0200
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2016, 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
@@ -32,7 +32,7 @@
  * @library ../share
  * @build common.*
  * @build utils.*
- * @run main/othervm -XX:+UsePerfData -Xms128M -XX:MaxMetaspaceSize=128M GcTest02
+ * @run main/othervm -XX:+UsePerfData -Xmx128M -XX:MaxMetaspaceSize=128M GcTest02
  */
 
 public class GcTest02 {
@@ -58,10 +58,4 @@
         // Assert that space has been utilized acordingly
         JstatResults.assertSpaceUtilization(measurement2, targetMemoryUsagePercent);
     }
-
-    private static void assertThat(boolean result, String message) {
-        if (!result) {
-            throw new RuntimeException(message);
-        };
-    }
 }