Package io.deephaven.hotspot
Class JvmIntrospectionContext
java.lang.Object
io.deephaven.hotspot.JvmIntrospectionContext
Utility class to facilitate obtaining data for safepoint pauses count and time between two points in code. A
safepoint pause is a "stop the world, pause all threads" event in the HotSpot JVM. Note full Garbage Collection
pauses are a dominant cause of safepoint pauses, but there are other triggers like:
- Deoptimization
- Biased lock revocation
- Thread dump
- Heap inspection
- Class redefinition
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlongNumber of safepoint pauses between the last two calls tosample()longTime in milliseconds fully paused in safepoints between the last two calls tosample()longTime in milliseconds getting to a full safepoint stop (safepoint sync time) between the last two calls tosample()voidSample garbage collection count and times at the point of call.booleanvoid
-
Constructor Details
-
JvmIntrospectionContext
public JvmIntrospectionContext()
-
-
Method Details
-
hasSafePointData
public boolean hasSafePointData() -
startSample
public void startSample() -
endSample
public void endSample()Sample garbage collection count and times at the point of call. -
deltaSafePointPausesCount
public long deltaSafePointPausesCount()Number of safepoint pauses between the last two calls tosample()- Returns:
- Number of safepoint pauses.
-
deltaSafePointPausesTimeMillis
public long deltaSafePointPausesTimeMillis()Time in milliseconds fully paused in safepoints between the last two calls tosample()- Returns:
- Time in milliseconds.
-
deltaSafePointSyncTimeMillis
public long deltaSafePointSyncTimeMillis()Time in milliseconds getting to a full safepoint stop (safepoint sync time) between the last two calls tosample()- Returns:
- Time in milliseconds
-