< prev index next >
test/serviceability/tmtools/jstat/utils/JstatGcResults.java
Print this page
*** 23,34 ****
/*
* 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
*
* Output description:
* S0C Current survivor space 0 capacity (KB).
* S1C Current survivor space 1 capacity (KB).
* S0U Survivor space 0 utilization (KB).
--- 23,34 ----
/*
* 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 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.000 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,52 ****
--- 43,54 ----
* 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 Number of STW events during Concurrent GC's.
+ * CGCT STW time during Concurrent GC's.
* GCT Total garbage collection time.
*
*/
package utils;
*** 100,118 ****
assertThat(GCT >= 0, "Incorrect time value for GCT");
assertThat(GCT >= YGCT, "GCT < YGCT (total garbage collection time < young generation garbage collection time)");
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) + ")");
}
private static final float FLOAT_COMPARISON_TOLERANCE = 0.0011f;
private static boolean checkFloatIsSum(float sum, float... floats) {
--- 102,125 ----
assertThat(GCT >= 0, "Incorrect time value for GCT");
assertThat(GCT >= YGCT, "GCT < YGCT (total garbage collection time < young generation garbage collection time)");
int FGC = getIntValue("FGC");
float FGCT = getFloatValue("FGCT");
if (FGC > 0) {
assertThat(FGCT > 0, "Number of full GC events is " + FGC + ", but FGCT is 0");
}
! int CGC = getIntValue("CGC");
! float CGCT = getFloatValue("CGCT");
! if (CGC > 0) {
! assertThat(CGCT > 0, "Number of concurrent GC events is " + CGC + ", but CGCT is 0");
! }
!
! assertThat(GCT >= (FGCT + CGCT), "GCT < YGCT (total garbage collection time < full generation garbage collection time)");
! assertThat(checkFloatIsSum(GCT, YGCT, FGCT, CGCT), "GCT != (YGCT + FGCT + CGCT) " + "(GCT = " + GCT + ", YGCT = " + YGCT
! + ", FGCT = " + FGCT + ", CGCT = " + CGCT + ", (YCGT + FGCT + CGCT) = " + (YGCT + FGCT + CGCT) + ")");
}
private static final float FLOAT_COMPARISON_TOLERANCE = 0.0011f;
private static boolean checkFloatIsSum(float sum, float... floats) {
< prev index next >