< prev index next >

test/serviceability/tmtools/jstat/utils/JstatGcResults.java

Print this page

        

@@ -23,12 +23,12 @@
 
 /*
  * Results of running the JstatGcTool ("jstat -gc <pid>")
  *
  * Output example:
- * (S0C    S1C    S0U    S1U      EC       EU        OC         OU       MC     MU    CCSC   CCSU   YGC     YGCT    FGC    FGCT     GCT
- * 512.0  512.0   32.0   0.0   288768.0 168160.6  83968.0     288.1    4864.0 2820.3 512.0  279.7   18510 1559.208   0      0.000 1559.208
+ * S0C    S1C    S0U    S1U      EC       EU        OC         OU       MC     MU    CCSC   CCSU   YGC     YGCT    FGC    FGCT    CGC    CGCT     GCT
+ * 512.0  512.0   32.0   0.0   288768.0 168160.6  83968.0     288.1    4864.0 2820.3 512.0  279.7   18510 1559.208   0      0.000    0     0.0  1559.208
  *
  * Output description:
  * S0C     Current survivor space 0 capacity (KB).
  * S1C     Current survivor space 1 capacity (KB).
  * S0U     Survivor space 0 utilization (KB).

@@ -43,10 +43,12 @@
  * CCSU    Compressed Class Space utilization
  * YGC     Number of young generation GC Events.
  * YGCT    Young generation garbage collection time.
  * FGC     Number of full GC events.
  * FGCT    Full garbage collection time.
+ * CGC     Concurrent Collections (STW phase)
+ * CGCT    Concurrent Garbage Collection Time (STW phase)
  * GCT     Total garbage collection time.
  *
  */
 package utils;
 

@@ -99,18 +101,25 @@
 
         float GCT = getFloatValue("GCT");
         assertThat(GCT >= 0, "Incorrect time value for GCT");
         assertThat(GCT >= YGCT, "GCT < YGCT (total garbage collection time < young generation garbage collection time)");
 
+        int CGC = getIntValue("CGC");
+        float CGCT = getFloatValue("CGCT");
+        assertThat(CGCT >= 0, "Incorrect time value for CGCT");
+        if (CGC > 0) {
+            assertThat(CGCT > 0, "Number of concurrent GC events is " + CGC + ", but CGCT is 0");
+        }
+
         int FGC = getIntValue("FGC");
         float FGCT = getFloatValue("FGCT");
         assertThat(FGCT >= 0, "Incorrect time value for FGCT");
         if (FGC > 0) {
             assertThat(FGCT > 0, "Number of full GC events is " + FGC + ", but FGCT is 0");
         }
 
         assertThat(GCT >= FGCT, "GCT < YGCT (total garbage collection time < full generation garbage collection time)");
 
-        assertThat(checkFloatIsSum(GCT, YGCT, FGCT), "GCT != (YGCT + FGCT) " + "(GCT = " + GCT + ", YGCT = " + YGCT
-                + ", FGCT = " + FGCT + ", (YCGT + FGCT) = " + (YGCT + FGCT) + ")");
+        assertThat(checkFloatIsSum(GCT, YGCT, CGCT, FGCT), "GCT != (YGCT + CGCT + FGCT) " + "(GCT = " + GCT + ", YGCT = " + YGCT
+                + ", CGCT = " + CGCT + ", FGCT = " + FGCT + ", (YCGT + CGCT + FGCT) = " + (YGCT + CGCT + FGCT) + ")");
     }
 }
< prev index next >