It is also possible to use ``GDB`` with these traceback addresses to debug
the program. For example, we can break at a given code location, as reported
-in the stack traceback:
-
- ::
+in the stack traceback::
$ gdb -nw stb
with :switch:`--load` instead of the ``addr2line`` tool. The main difference
is that you need to copy the Load Address output in the traceback ahead of the
sequence of addresses. And the default mode of ``gnatsymbolize`` is equivalent
-to that of ``addr2line`` with the above switches, so none of them is needed:
+to that of ``addr2line`` with the above switches, so none of them is needed::
- ::
$ gnatmake stb -g -bargs -E
$ stb
the program. For example, we can break at a given code location, as reported
in the stack traceback:
-@quotation
-
@example
$ gdb -nw stb
(gdb) break *0x401373
Breakpoint 1 at 0x401373: file stb.adb, line 5.
@end example
-@end quotation
It is important to note that the stack traceback addresses do not change when
debug information is included. This is particularly useful because it makes it
sequence of addresses. And the default mode of @code{gnatsymbolize} is equivalent
to that of @code{addr2line} with the above switches, so none of them is needed:
-@quotation
-
-
-@table @asis
-
-@item ::
-
+@example
$ gnatmake stb -g -bargs -E
$ stb
Call stack traceback locations:
0x401373 0x40138b 0x40139c 0x401335 0x4011c4 0x4011f1 0x77e892a4
-
-@table @asis
-
-@item $ gnatsymbolize –load stb 0x400000 0x401373 0x40138b 0x40139c 0x401335
-
-0x4011c4 0x4011f1 0x77e892a4
-@end table
+$ gnatsymbolize --load stb 0x400000 0x401373 0x40138b 0x40139c 0x401335
+ 0x4011c4 0x4011f1 0x77e892a4
0x00401373 Stb.P1 at stb.adb:5
0x0040138B Stb.P2 at stb.adb:10
0x004011c4 __tmainCRTStartup at ???
0x004011f1 mainCRTStartup at ???
0x77e892a4 ??? at ???
-@end table
-@end quotation
+@end example
@subsubheading Tracebacks From Exception Occurrences