How is the debug information organized in a compiled C/C++ program? What does it contain?
How is the debug information used by the debugger, e.g. gdb, and how can I read the debug information be开发者_如何学编程tter than nm or objdump?
The debugging information depends on the operating system - gdb uses whatever the native format is. On many UNIX-like systems, debugging information is stored in DWARF format. You can use libdwarf and dwarfdump to examine this information.
EDIT: On Linux readelf -w a.out will print all DWARF debug info contained in the executable (also works for shared libraries and object files).
加载中,请稍侯......
精彩评论