Linux学习笔记:GDB常用命令
时间:2010-09-24 来源:weichsel
# 启动程序
run //指定参数;输入/输出重定向;
set args // 设置参数
# 中断程序
支持三种中断方式:breakpoints、watchpoints、catchpoints
b
info b
delete
clear
condition
commands
disable
enable
catch
watch
# 查询堆栈
bt
frame
info frame
up
down
return
# 程序执行
start
continue
step
next
until
finish
call
# 查询变量
print //1) 格式控制/d /x /o /t; 2)数组打印 firstVal@elemNum
x // 查询内存值
info locals
display
disassemble
set print
# 浏览代码
list -
set listsize
search
相关阅读 更多 +