GDB进行汇编级的调试
2013-08-04 15:34
316 查看
gcc -S test.c
生成test.s文件
as -o test.o -gstabs test.s
生成test.o文件
gcc -o test -Wall test.o
gdb test
以下为man as得到到信息
--gen-debug
Generate debugging information for each assembler source
line using whichever debug format is preferred by the
target. This currently means either STABS, ECOFF or
DWARF2.
--gstabs
Generate stabs debugging information for each assembler
line. This may help debugging assembler code, if the
debugger can handle it.
--gstabs+
Generate stabs debugging information for each assembler
line, with GNU extensions that probably only gdb can
handle, and that could make other debuggers crash or
refuse to read your program. This may help debugging
assembler code. Currently the only GNU extension is the
location of the current working directory at assembling
time.
生成test.s文件
as -o test.o -gstabs test.s
生成test.o文件
gcc -o test -Wall test.o
gdb test
以下为man as得到到信息
--gen-debug
Generate debugging information for each assembler source
line using whichever debug format is preferred by the
target. This currently means either STABS, ECOFF or
DWARF2.
--gstabs
Generate stabs debugging information for each assembler
line. This may help debugging assembler code, if the
debugger can handle it.
--gstabs+
Generate stabs debugging information for each assembler
line, with GNU extensions that probably only gdb can
handle, and that could make other debuggers crash or
refuse to read your program. This may help debugging
assembler code. Currently the only GNU extension is the
location of the current working directory at assembling
time.
相关文章推荐
- 如何用gdb进行汇编级的调试
- 使用 gdb 对程序进行汇编级调试
- 使用 gdb 对程序进行汇编级调试
- (转载)如何用gdb进行汇编级的调试
- gdb中汇编调试
- 利用GDB在远程开发机进行调试
- 一步一步用debugserver + lldb代替gdb进行动态调试(整理与补充)
- 在win下使用gdb进行调试
- 用GDB Server进行远程调试
- (转载)GDB 进行调试 使用心得
- gdb中汇编调试
- eclipse + cdt + gdb 进行arm linux 交叉调试
- 用gdb调试nasm汇编程序
- GDB调试汇编堆栈过程分析
- 利用终端进行GDB调试
- (基于 TI8168) LINUX下QT环境配置,能用GDB+GDBSERVER进行调试
- 【嵌入式Linux学习七步曲之第二篇 ARM+Linux开发环境】gdb+gdbserver的方式进行ARM程序调试
- 1.编写一个简单的C语言程序:根据输入的两个整数求平均值并且在终端输出,通过gcc编译器得到它的汇编程序文件。 2.编写一个C语言程序:打印输出所有“水仙花数”,用gdb调试程序(给出步骤)。所谓“
- gdb的简单使用和gdb+gdbserver方式进行ARM程序调试
- 利用GDB对程序进行调试