Native Inspect Manual (H06.03+)
Table Of Contents
- What’s New in This Manual
- About This Manual
- 1 Introducing Native Inspect
- Native Inspect on TNS/E Systems
- Debuggers on NonStop TNS/E Systems
- Origins of Native Inspect
- Process Debugging With Native Inspect
- Debugging Multiple Processes
- Global Debugging
- Debugging TNS Processes
- Snapshot File Analysis
- Debugging DLLs
- Handling Events
- Switching Debuggers (To or From Inspect and Visual Inspect)
- Stopping Native Inspect
- Differences Between Native Inspect and WDB and GDB
- 2 Using Native Inspect
- Quick Start for Inspect Users
- Preparing to Debug Using Native Inspect
- Sample Native Inspect Session
- Start Your Program Under Native Inspect
- Load Symbols
- Determine Compilation-Time Source Name
- Set Source Name Mapping
- Add Current Directory to Source Search Path
- List Source
- Set a Breakpoint on main()
- Continue Execution
- Trace the Stack (Back Trace)
- List Source
- Step Execution (Over Any Function Calls)
- Print a Variable
- Step Execution (Over Any Function Calls)
- Step In to a Called Function
- Set a Memory Access Breakpoint (MAB)
- Trace the Stack (Back Trace)
- List Source
- Continue Listing Source
- Set a Breakpoint on Line 52
- Continue Execution
- Display a Structure
- Enable “pretty” Printing
- Modify a Structure Field
- Terminate Program and Session
- 3 Syntax of Native Inspect Commands
- Categories of Native Inspect Commands
- Syntax of Common Command Elements
- # command
- a command
- add-symbol-file command
- amap command
- attach command
- base command
- break command, tbreak command
- bt command
- can command
- cd command
- commands command
- comment command
- condition command
- continue command
- d command
- delete command
- delete display command
- detach command
- dir command
- disable command
- disable display command
- disassemble command, da command
- display command
- dmab command
- down command, down-silently command
- enable command
- enable display command
- env command
- eq command
- exit command
- fc command
- files command
- finish command
- fn command
- frame command, select-frame command
- help command, help option
- hold command
- i command
- ignore command
- ih command
- info command
- jb command
- jump command
- kill command
- list command
- log command
- ls command
- mab command
- map-source-name command
- mh command
- modify command
- next command, nexti command
- nocstm option
- output command
- print command
- priv command
- ptype command
- pwd command
- quit command
- reg command
- save command
- select-frame command
- set command (environment)
- set command (variable)
- show command
- snapshot command
- source command
- step command, stepi command
- switch command
- symbol command, symbol-file command
- tbreak command
- tj command, tu command
- tn command
- unload-symbol-file command
- until command
- up command, up-silently command
- vector command
- version option
- vq command
- wait command
- whatis command
- x command
- 4 Using Tcl Scripting
- A Command Mapping With Debug and Inspect
- Glossary
- Index

Introducing Native Inspect
Native Inspect Manual—528122-003
1-13
Debugging Multiple Processes
The current process is the process to which all debugging commands apply and the
process for which Native Inspect waits for events.
When Native Inspect has no current process, the command prompt includes the CPU
number and “-2” as the process number. For example:
(eInspect 3,-2):
Abbreviating Native Inspect Commands
You can truncate Native Inspect command names provided that the abbreviation is not
ambiguous. Commonly used command abbreviations are listed as aliases in
Section 3, Syntax of Native Inspect Commands.
For aliases, even ambiguous abbreviations are allowed. For example, the letter s is
defined as an alias for the step command even though many other command names
start with s.
You can test abbreviations by using them as arguments to the help command, help
option.
Debugging Multiple Processes
Native Inspect provides limited support for debugging multiple TNS/E native processes
in both the Guardian and OSS environments. Native Inspect does not provide the
same level of multiprocess debugging capabilities that Inspect has traditionally
provided and that is available on TNS/E systems by debugging with Visual Inspect.
To do multiprocess debugging, either use separate instances of Native Inspect or use
Visual Inspect.
If you use Native Inspect for multiprocess debugging, you can choose either of these
strategies:
•
Use a separate Native Inspect instance for each process so that you are issuing
debug requests from separate terminal sessions.
•
Use one instance of Native Inspect for all processes so that one process is the
current process and the other processes are in the background.
Two Processes Can Run Under One Instance of Native Inspect
Suppose that you are running Native Inspect and are debugging a process (this is the
“current process” of the debugger, or the debugging target). Another process will
automatically be given to your existing instance of Native Inspect if a TNS/E native
process causes a debugger to be invoked, and the TNS/E process is running in the
same CPU and has the same user ID as your current process (or if you are using the
super ID).
Two processes are then under the control of one instance of Native Inspect. See
Example of Using Multiple Instances of Native Inspect on page 1-15.










