Native Inspect Manual (H06.07+)

Introducing Native Inspect
Native Inspect Manual528122-006
1-18
Debugging TNS Processes
To set a global breakpoint, you must enable privileged debugging and then specify
the -g flag when setting a breakpoint. Global breakpoints are triggered by any
process that executes the code on which the breakpoint is set.
Global debugging mode begins when the first global breakpoint is set, and ends
when the last global breakpoint is deleted. While global debugging is in effect, all
other debugging in the CPU is suspended.
Native Inspect detects debugging events only when it is waiting. The debugger
cannot detect debugging events when prompting the user for input. For this
reason, you should periodically issue the wait command so that Native Inspect can
detect any debugging events that might have occurred. When waiting, you can
press the Break key to redisplay the command prompt.
The super ID has the unique ability to vector to and examine processes running in
the current CPU without establishing a debugging session with that process.
When privileged debugging mode is enabled, the attach command issues a
DEBUGNOW request rather than a DEBUG request.
Debugging TNS Processes
Native Inspect does not support debugging TNS processes. However, a TNS process
comes under the control of Native Inspect when the Inspect subsystem (T9226) is not
running.
If the current process is a TNS process, in Native Inspect. you can:
Create a snapshot of the TNS process for later analysis with Visual Inspect or
Inspect (using the save command)
Display a stack trace of the TNS process (using the bt command)
Continue execution (using the continue command)
Transfer the TNS process to Inspect once the Inspect subsystem is started (using
the switch command)
Stop the TNS process or exit the debugger (using the kill command)
For TNS programs that are executing OCA-generated TNS/E code, Native Inspect can
debug the program, nonsymbolically, at the TNS/E machine level. You can use
commands such as continue, finish, next, step, and until. Native Inspect applies the
commands to the underlying TNS/E native view rather than to the TNS process itself.
Also, the bt command can display a TNS stack trace.
Caution. Use the super ID’s vector capability with care. The process might be executing, and
you cannot use execution control commands or commands that alter the process state.