RFR(XS) serviceability/sa/jmap-hprof/JMapHProfLargeHeapTest.java failing because expects HPROF JAVA PROFILE 1.0.1 file format

Markus Gronlund markus.gronlund at oracle.com
Wed Mar 2 22:18:13 UTC 2016


Hi Erik,

I think this looks good.

Thanks for fixing.

Markus

-----Original Message-----
From: Erik Gahlin 
Sent: den 2 mars 2016 23:08
To: serviceability-dev at openjdk.java.net
Subject: RFR(XS) serviceability/sa/jmap-hprof/JMapHProfLargeHeapTest.java failing because expects HPROF JAVA PROFILE 1.0.1 file format

Hi,

Could I have a review of a fix for

"8150986: serviceability/sa/jmap-hprof/JMapHProfLargeHeapTest.java
failing because expects HPROF JAVA PROFILE 1.0.1 file format"
https://bugs.openjdk.java.net/browse/JDK-8150986

It's a test update to accommodate the removal of 1.0.1 HPROF file format support that happened with
https://bugs.openjdk.java.net/browse/JDK-8144732

Thanks
Erik

diff --git
a/test/serviceability/sa/jmap-hprof/JMapHProfLargeHeapTest.java
b/test/serviceability/sa/jmap-hprof/JMapHProfLargeHeapTest.java
--- a/test/serviceability/sa/jmap-hprof/JMapHProfLargeHeapTest.java
+++ b/test/serviceability/sa/jmap-hprof/JMapHProfLargeHeapTest.java
@@ -54,7 +54,6 @@

  public class JMapHProfLargeHeapTest {
      private static final String HEAP_DUMP_FILE_NAME = "heap.hprof";
-    private static final String HPROF_HEADER_1_0_1 = "JAVA PROFILE 1.0.1";
      private static final String HPROF_HEADER_1_0_2 = "JAVA PROFILE 1.0.2";
      private static final long M = 1024L;
      private static final long G = 1024L * M; @@ -79,17 +78,7 @@
              }
          }

-        // Small heap 22 megabytes, should create 1.0.1 file format
-        testHProfFileFormat("-Xmx1g", 22 * M, HPROF_HEADER_1_0_1);
-
-        /**
-         * This test was deliberately commented out since the test 
system lacks
-         * support to handle the requirements for this kind of heap 
size in a
-         * good way. If or when it becomes possible to run this kind of 
tests in
-         * the test environment the test should be enabled again.
-         * */
-        // Large heap 2,2 gigabytes, should create 1.0.2 file format
-        // testHProfFileFormat("-Xmx4g", 2 * G + 2 * M, 
HPROF_HEADER_1_0_2);
+        testHProfFileFormat("-Xmx1g", 22 * M, HPROF_HEADER_1_0_2);
      }

      private static void testHProfFileFormat(String vmArgs, long heapSize,


More information about the serviceability-dev mailing list