Migrating from Inspect to Native Inspect
Migrating from Inspect to Native Inspect
10 of 15 Hewlett-Packard Company 543427-002
Value History
Native Inspect saves displayed values in a
value history list, which is analogous to the
command history list. Entries are identified
by a $-prefixed ordinal number that is
printed at the beginning of print command
output. Values can be recalled and used with
other commands. For example,
print $3
Using Convenience Variables
Value history variables are one example of
GDB convenience variables, whose names
are prefixed with a $. To define variables to
hold values commonly used in your
debugging session, use the set command.
For example:
set $curObj=obj->next->next
You can then use the variable name with
other debugging commands. For example:
print $curObj->flags
Creating a Custom File
To automatically execute commands at the
startup of each Native Inspect session, place
them in this file in your logon default
subvolume:
EINSCSTM
Controlling Output
By default, Native Inspect paginates output,
prompting you after each screen page of
output. To disable pagination, use the
command:
set pagination off
Destructive commands often issue a
confirmation prompt before performing their
action. To disable the prompt, use this
command:
set confirm off
Limitations
Native Inspect does not yet support the
ability to list information about a
program’s open files. (Inspect INFO
OPENS).
Native Inspect support for pTAL is
currently limited. In many respects,
pTAL is treated like C. You must use C-
style pointer dereferencing and
transform pTAL expressions to
corresponding C expressions.
Online help reflects GDB online help,
which is not as complete as Inspect
online help.
Native Inspect does not support the
following Inspect formatting
capabilities:
o PIC or FORMAT
o SPI formatting
o System types
Native Inspect does not support
convenience commands, such as
defining function keys, displaying status
line information, and so on.
Resources
The Native Inspect Manual, part number
528122-005, is available in the NonStop
Technical Library at
http://www.hp.com/go/ntl.
A wide variety of resources are available on
the internet about GDB and WDB, the HP-
UX variant. Native Inspect is currently
based on GDB version 4.17.
GDB Home
http://www.gnu.org/software/gdb/
WDB Home
http:www.hp.com/go/wdb
TCL Home
http://www.tcl.tk/
GDB Quick Reference card
http://refcards.com/refcards/gdb/gdb-
refcard-letter.pdf
Several books are also available on GDB,
including an O’Reilly GDB Pocket
Reference.










