Guardian Programmer's Guide

Table Of Contents
Debugging, Trap Handling, and Signal Handling
Guardian Programmer’s Guide 421922-014
25 - 3
Getting a Process Into the Debug State
Using the DEBUG procedure
Using the PROCESS_DEBUG_ procedure
Using the PROCESS_CREATE_ or PROCESS_LAUNCH_ procedure
Using the RUND command (or the TACL run option DEBUG)
Using the DEBUG command (from the TACL prompt)
Using the Visual Inspect application (TNS/R and TNS/E environments only)
Using the Native Inspect application (TNS/E environment only)
Specifying a breakpoint
The following paragraphs describe each of the above alternatives.
Using the DEBUG Procedure
You can enter the Debug state by calling the DEBUG procedure. By calling this
procedure, you invoke the debugger on your own process:
CALL DEBUG;
The calling process enters the Debug state immediately when this call is made.
Using the PROCESS_DEBUG_ Procedure
You can enter the Debug state by calling the PROCESS_DEBUG_ procedure. Using
this procedure, you can invoke the debugger on your own process or on another
process.
To invoke the debugger on another process, you must supply the process handle of the
process you wish to debug:
CALL PROCESS_DEBUG_(PROCESS^HANDLE);
To debug another process this way, your process must either have super ID access, be
the group manager of the process access ID, or be a process with the same process
access ID as the target process.
You can invoke the debugger on your own process by calling the PROCESS_DEBUG_
procedure without any options. However, the preferred method of invoking the
debugger on your own process is by calling DEBUG.
Using the PROCESS_CREATE_ or
PROCESS_LAUNCH_ Procedure
You can run the debugger on a new process as soon as the process starts by
supplying the debug-options parameter to the PROCESS_CREATE_ procedure. To
run the debugger, bit 12 of this parameter must be set to 1.