Tdump - Red Hat ENTERPRISE LINUX 3 - DEBUGGING WITH GDB Manual

Debugging with gdb
Hide thumbs Also See for ENTERPRISE LINUX 3 - DEBUGGING WITH GDB:
Table of Contents

Advertisement

Chapter 12. Tracepoints
(gdb) tfind start
(gdb) while ($trace_frame != -1)
printf "Frame %d, PC = %08X, SP = %08X, FP = %08X\n", \
$trace_frame, $pc, $sp, $fp
tfind
end
Frame 0, PC = 0020DC64, SP = 0030BF3C, FP = 0030BF44
Frame 1, PC = 0020DC6C, SP = 0030BF38, FP = 0030BF44
Frame 2, PC = 0020DC70, SP = 0030BF34, FP = 0030BF44
Frame 3, PC = 0020DC74, SP = 0030BF30, FP = 0030BF44
Frame 4, PC = 0020DC78, SP = 0030BF2C, FP = 0030BF44
Frame 5, PC = 0020DC7C, SP = 0030BF28, FP = 0030BF44
Frame 6, PC = 0020DC80, SP = 0030BF24, FP = 0030BF44
Frame 7, PC = 0020DC84, SP = 0030BF20, FP = 0030BF44
Frame 8, PC = 0020DC88, SP = 0030BF1C, FP = 0030BF44
Frame 9, PC = 0020DC8E, SP = 0030BF18, FP = 0030BF44
Frame 10, PC = 00203F6C, SP = 0030BE3C, FP = 0030BF14
Or, if we want to examine the variable
(gdb) tfind start
(gdb) while ($trace_frame != -1)
printf "Frame %d, X == %d\n", $trace_frame, X
tfind line
end
Frame 0, X = 1
Frame 7, X = 2
Frame 13, X = 255
12.2.2.

tdump

This command takes no arguments. It prints all the data collected at the current trace snapshot.
(gdb) trace 444
(gdb) actions
Enter actions for tracepoint #2, one per line:
collect $regs, $locals, $args, gdb_long_test
end
(gdb) tstart
(gdb) tfind line 444
#0
gdb_test (p1=0x11, p2=0x22, p3=0x33, p4=0x44, p5=0x55, p6=0x66)
at gdb_test.c:444
444
printp( "%s: arguments = 0x%X 0x%X 0x%X 0x%X 0x%X 0x%X\n", )
(gdb) tdump
Data collected at tracepoint 2, trace frame 1:
d0
0xc4aa0085
d1
0x18
d2
0x80
d3
0x33
d4
0x71aea3d
d5
0x22
at each source line in the buffer:
X
-995491707
24
128
51
119204413
34
99

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the ENTERPRISE LINUX 3 - DEBUGGING WITH GDB and is the answer not in the manual?

Questions and answers

Table of Contents