!! |
execute the previous command |
r |
execute the previous command |
!<num> |
execute command number |
! -<num> |
execute command <num> before the current |
history |
list a history of dbx commands |
. |
read (source) dbx commands from a file |
run |
start the current process |
kill |
kill the controlled process |
debug |
print name and arguments of program being debugged |
debug <prog> [<core>] |
debug <prog> with corefile <core>(optional) |
debug <prog> <pid> |
attach to process <pid> |
detach |
detaches dbx from the controlled process |
runargs <args> |
set the run arguments for the current program |
runargs
[>|>>] <file> |
output redirection for a program |
runargs
< <file> |
input redirection for a program |
print [-r] [-d]
<statement> |
prints
<statement>. |
|
<statement> can be a function call, a local variable, or a
constant |
|
(though not a macro, because the c preprocessor and dbx don't |
|
work and play well together |
-r |
-r prints inherited members in C++ |
-d |
uses dynamic (RTTI) type information to determine the type of |
|
<statement> |
print <arr>[<first>..<last>:<stride>] |
print an array
slice |
examine < addr> = [ <fmt> ] |
display an address in a format |
examine <addr 1>, <addr 2> / fmt |
examine memory in the given format |
display <expr> |
display an expression |
undisplay <num> |
turn off displaying expression number <num> |
|
(0 turns off all displays) |
where |
display the stack trace. |
up |
move up one stack frame |
down |
move down one stack frame |
i |
instruction (disassembly) |
d,D |
decimal (2 or 4 bytes) |
o,O |
octal (2 or 4 bytes) |
x,X |
hexadecimal (2 or 4 bytes) |
b |
octal (1 byte) |
c |
character |
w |
wide character |
s |
string |
W |
wide character string |
f |
hex and float (4 bytes, 6 digit prec.) |
F |
hex and float (8 bytes, 14 digit prec.) |
g |
same as `F' |
E |
hex and float (16 bytes, 14 digit prec.) |
ld,lD |
decimal (4 bytes, same as D) |
lo,lO |
octal (4 bytes, same as O) |
lx,LX |
hexadecimal (4 bytes, same as X) |
Ld,LD |
decimal (8 bytes) |
Lo,LO |
octal (8 bytes) |
Lx,LX |
hexadecimal (8 bytes) |
stop <event>
<modifier> |
stop execution when <event> occurs |
trace <event>
<modifier> |
print out a message when <event> happens. |
tracei <event>
<modifier> |
like above, but works on assembly
instructions |
when <event> <command>
<modifier> |
execute <command> when <event>happens |
dbxenv trace_speed <num> |
pause <num> seconds between traces |
clear [<lineno>] |
clears events at <lineno> (defaults to current
line) |
status |
Print trace's, when's, and stop's in effect |
status <hid> |
print the status of handler (event) <hid> |
status -s |
print all events in a form that dbx can read |
|
(dbx) status -s > bpts |
|
 |
|
(dbx) source bpts |
delete <num> |
delete handler <num> (0 deletes all handlers) |
handler -disable <num> |
disables a handler |
handler -enable <num> |
enables a handler |
call <proc>
<[params]> |
call <proc> with the given parameters |
cont |
continues execution |
cont at <line> <id> |
continues execution at <line> in lwp <id> |
next |
next instruction (skip calls) |
nexti |
next assembly instruction (skip calls) |
step |
next instruction (enter calls) |
stepi |
next assembly instruction (enter calls) |
regs |
display the registers |
dbxenv follow_fork_mode <spec> |
<spec> can be child, parent, or
ask |
|
if <spec> equals parent, stay with the parent after a call to
fork(2) |
|
if <spec> equals child, follow the child after a call to fork(2) |
|
if <spec> equals ask, then ask which to follow after a call to fork(2) |
assign
<var> = <exp> |
assign <exp> to <var> |
in <func> |
When the program enters <func> |
at <line> |
When <line> in the current file is about to be executed |
at
<filename>:<line> |
When <line> in
<filename> is about to be
executed |
inmethod <func> |
Entry into any method named <func> |
infunction <func> |
Entry into any overloaded version of <func> |
inclass <class> |
Trigger in any member of <class> |
inmember <class> |
Entry into any member function of a class (c++ only) |
inobject
 |
Trigger in any member of an instance of a class (c++ only) |
modify
<addr-expr> [,
<size-expr>] |
Trigger when the address range
is written to |
throw |
A C++ exception has been thrown |
throw <type> |
A C++ exception of type <type> has been thrown. |
check <type> |
checks for runtime errors specified by <type> (see
below) |
check <type> <places> |
check for runtime errors in <places> where
<places> |
|
is a comma separated list of files, functions, or loadobjects. |
|
this can be used to focus RTC on specific places. |
uncheck <type> |
stops checking for runtime errors. |
showleaks [-v] |
shows memory leaks (-v for verbose) |
showmemuse [-v] |
shows memory usage (-v for verbose) |
suppress |
History of suppress and unsuppress commands |
suppress <errors> |
Suppress <errors> everywhere. |
suppress <errors> <places> |
Suppress <errors> in <places> where
<places> |
|
is a comma separated list of files, functions, or loadobjects. |
unsuppress <errors> |
Stop suppressing <errors> everywhere. |
unsuppress <errors> <places> |
Stop suppressing <errors> in
<places>. |
-access |
Stops the process whenever a memory access error occurs. |
|
This checks for baf, duf, maf, mar, maw, oom, rua, rui, wro, wua |
|
If you set dbxenv rtc_auto to ``on'', then access errors will be |
|
logged to a file rather than halting execution (controlled by rtc_error_log_filename) |
-leaks |
Generates a list of memory leaks when the program terminates. |
|
checks for aib, air, mel. The report is not verbose by default, |
|
controlled by rtc_mel_at_exit. Also, you can use showleaks at any time |
-memuse |
Generates a list of blocks in use when the program terminates.
Implies -leaks |
|
This report is not verbose by default, and controlled by rtc_biu_at_exit |
-all |
Checks for memory usage and leaks |
list |
list the default number of lines in the current file |
list <n> |
list line number <n> in the current file |
list +<n> |
list the next <n> lines in the current file |
list
<n1>, [+]<n2> |
list lines from <n1> to <n2> (or the next
<n2> lines if +<n2>) |
list
<filename>:<n> |
list line <n> in filename. |
list -i |
intermix assembly lines between source lines |
list -w |
list a window of 10 lines. |
edit
<filename> |
edit (in $EDITOR)
<filename> |
edit <proc> |
edit file containing procedure <proc> |
dis
<addr> [/<count>] |
disassemble <count> instructions at
<addr> |
whereis <func> |
Returns the file containing <func> |
whatis <name> |
returns the type of <name>. Example: ``whatis
main'' would |
|
return ``void main(int argc, char **argv)'' |
collector |
collect information about performance. |
__cb_prompt |
A ksh function that gets called before the prompt is
displayed |
dalias |
set (or list) a dbx alias |
ignore <signal> |
ignore signal named/numbered <signal> |
(un)intercept
<typename> |
(do not) intercept throws of type
<typename> |
(un)intercept -a |
(do not) intercept all throws |
(un)intercept -x
<typename> |
(Do not) intercept throws of type
<typename>(use with above) |
(un)intercept |
list intercepted types |