Class StackWalkerUtils
java.lang.Object
com.ibm.j9ddr.vm29.j9.stackwalker.StackWalkerUtils
-
Field Summary
Modifier and TypeFieldDescriptionstatic final boolean
static final boolean
static final int
Number of CorruptDataExceptions from iterate-o-slots logic that we report before disabling the o-slots walkstatic final Logger
Stack walker logger, can be enabled for debugging stack walker issues when running inside other tools, for example Memory Analyzer. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
static void
enableVerboseLogging
(int level) Enables stackwalk verbose logging through j.u.logging - similar in appearance to -verbose:stackwalk output from native.static void
enableVerboseLogging
(int level, PrintStream os) static void
handleOSlotsCorruption
(WalkState walkState, String className, String methodName, CorruptDataException ex) Since walking OSlots touches a lot more code than just doing a frame walk, we have a layer of corruption handling just above the o-slots logic.static UDATA
JIT_RESOLVE_PARM
(WalkState walkState, int parmNumber) static boolean
static void
static void
This function is a little overloaded.static void
swPrintMethod
(WalkState walkState) static void
swPrintMethod
(WalkState walkState, com.ibm.j9ddr.vm29.pointer.generated.J9MethodPointer method) static void
WALK_I_SLOT
(WalkState walkState, PointerPointer slot) static void
WALK_INDIRECT_I_SLOT
(WalkState walkState, PointerPointer slot, VoidPointer ind) static void
WALK_INDIRECT_O_SLOT
(WalkState walkState, PointerPointer slot, VoidPointer ind) static void
WALK_METHOD_CLASS
(WalkState walkState) static void
WALK_NAMED_I_SLOT
(WalkState walkState, PointerPointer slot, String tag) static void
WALK_NAMED_INDIRECT_I_SLOT
(WalkState walkState, PointerPointer intSlot, VoidPointer indirectSlot, String tag) static void
WALK_NAMED_INDIRECT_O_SLOT
(WalkState walkState, PointerPointer objectSlot, VoidPointer indirectSlot, String tag) static void
WALK_NAMED_O_SLOT
(WalkState walkState, PointerPointer slot, String tag) static void
WALK_O_SLOT
(WalkState walkState, PointerPointer slot)
-
Field Details
-
logger
Stack walker logger, can be enabled for debugging stack walker issues when running inside other tools, for example Memory Analyzer. -
INITIAL_O_SLOTS_CORRUPTION_THRESHOLD
public static final int INITIAL_O_SLOTS_CORRUPTION_THRESHOLDNumber of CorruptDataExceptions from iterate-o-slots logic that we report before disabling the o-slots walk- See Also:
-
DEBUG_STACKMAP
public static final boolean DEBUG_STACKMAP- See Also:
-
DEBUG_LOCALMAP
public static final boolean DEBUG_LOCALMAP- See Also:
-
-
Constructor Details
-
StackWalkerUtils
public StackWalkerUtils()
-
-
Method Details
-
swPrintf
This function is a little overloaded. As well as determining if a message should be printed out for the message level chosen by the tool running the stack walker we also allow for someone turning on logging for debug to get details about the stack walker while running (for example) Memory Analyzer.- Parameters:
walkState
-level
-message
-args
-
-
swPrintMethod
- Throws:
CorruptDataException
-
swPrintMethod
public static void swPrintMethod(WalkState walkState, com.ibm.j9ddr.vm29.pointer.generated.J9MethodPointer method) throws CorruptDataException - Throws:
CorruptDataException
-
WALK_METHOD_CLASS
- Throws:
CorruptDataException
-
WALK_NAMED_INDIRECT_O_SLOT
public static void WALK_NAMED_INDIRECT_O_SLOT(WalkState walkState, PointerPointer objectSlot, VoidPointer indirectSlot, String tag) throws CorruptDataException - Throws:
CorruptDataException
-
WALK_NAMED_INDIRECT_I_SLOT
public static void WALK_NAMED_INDIRECT_I_SLOT(WalkState walkState, PointerPointer intSlot, VoidPointer indirectSlot, String tag) throws CorruptDataException - Throws:
CorruptDataException
-
WALK_INDIRECT_O_SLOT
public static void WALK_INDIRECT_O_SLOT(WalkState walkState, PointerPointer slot, VoidPointer ind) throws CorruptDataException - Throws:
CorruptDataException
-
WALK_INDIRECT_I_SLOT
public static void WALK_INDIRECT_I_SLOT(WalkState walkState, PointerPointer slot, VoidPointer ind) throws CorruptDataException - Throws:
CorruptDataException
-
WALK_NAMED_O_SLOT
public static void WALK_NAMED_O_SLOT(WalkState walkState, PointerPointer slot, String tag) throws CorruptDataException - Throws:
CorruptDataException
-
WALK_NAMED_I_SLOT
public static void WALK_NAMED_I_SLOT(WalkState walkState, PointerPointer slot, String tag) throws CorruptDataException - Throws:
CorruptDataException
-
WALK_O_SLOT
public static void WALK_O_SLOT(WalkState walkState, PointerPointer slot) throws CorruptDataException - Throws:
CorruptDataException
-
WALK_I_SLOT
public static void WALK_I_SLOT(WalkState walkState, PointerPointer slot) throws CorruptDataException - Throws:
CorruptDataException
-
JIT_RESOLVE_PARM
public static UDATA JIT_RESOLVE_PARM(WalkState walkState, int parmNumber) throws CorruptDataException - Throws:
CorruptDataException
-
resetOSlotsCorruptionThreshold
public static void resetOSlotsCorruptionThreshold() -
oSlotsCorruptionThresholdReached
public static boolean oSlotsCorruptionThresholdReached() -
handleOSlotsCorruption
public static void handleOSlotsCorruption(WalkState walkState, String className, String methodName, CorruptDataException ex) Since walking OSlots touches a lot more code than just doing a frame walk, we have a layer of corruption handling just above the o-slots logic. We have oslotsCorruptionThreshold attempts, then give up. This method is called in the catch block just below the top-level if (J9_STACKWALK_ITERATE_O_SLOTS) {} conditional. -
enableVerboseLogging
public static void enableVerboseLogging(int level) Enables stackwalk verbose logging through j.u.logging - similar in appearance to -verbose:stackwalk output from native. -
enableVerboseLogging
-
disableVerboseLogging
public static void disableVerboseLogging()
-