GDB Vs. WinDbg Commands
2012-02-04 04:17
831 查看
Here are a list of various useful commands that come in handy
More to follow on threads and other sub-commands.
Command / Option description | GDB Command | WinDbg Command / GUI operation descriptions |
---|---|---|
Enabling post-mortem default debugger | Not applicable on any Unix/Linux OS | To register as the default debugger type “windbg -I” and to use Dr.Watson use “drwtsn32 -i” |
Invoking Debugger with core file or dump file (as called in windows) | gdb <executable-file> <core-file> | Windbg-y SymbolPath -i ImagePath -z DumpFileName <ExecutableName> |
Attaching to a Running Process | gdb <executable> <pid> | windbg -p <pid> |
Repeat Last Command | Hit the enter key the most previous command is repeated. | Hit the enter key the most previous command is repeated. |
Display debugger command(s) while performing GUI operations in the debugger | Not applicable. You’ll have to type in your commands here. | .bpcmds |
Enabling Source level debugging | Enabled for files compiled with -g option. list / list {linenum} / list {filename:linenum} to display source file. | windbg <executable> <arguments> “File->Open Source File…”. Then hit the F5 key to run the program. The program stops at the specified breakpoint. |
Setting break point in a certain line in the code | break <line> break <source>.<line> break function_name break cpp_class::function(params) | bp @@masm(`FileName:LineNumber+`) |
Execute / Run program to a breakpoint or end of execution | Run r | go g |
Step over to next instruction | next | p |
Step into function / method | step | t |
Display variable contents | print variable_name | dv local_variable_name |
Dump memory contents | dump | d{a|b|c|d|D|f|p|q|u|w|W} |
Back track and display stack frames from current frame | bt <number-of-stack-frames> | kc k[b|p|P|v] [c] [f] [L] [FrameCount] |
相关文章推荐
- gdb vs. dbx: commands mapping and feature comparison
- vs2013+WDK8.1+WinDbg调试驱动开发环境配置(多帖子整理,水原创)
- VS 2013驱动开发 + Windbg + VM双机调试(亲测+详解)
- GDB - COMMANDS
- Debugging with GDB: Introduction to Commands, Print and Print-Object
- VisualGDB:使用VS创建CMake Linux项目
- gdb和windbg常用调试命令对照
- VELT-0.1.5开发:在vs2013下编译gdb
- VisualGDB系列4:概述-Linux程序与VS
- VS 2013驱动开发 + Windbg + VM双机调试(亲测+详解)
- 使用VS+VisualGDB编译调试Linux程序
- idb vs gdb
- VisualGDB系列6:远程导入Linux项目到VS中
- 关于VS 使用GDB工具调试ADT下JNI时遇到的一些问题的解决
- lldb vs gdb 命令对比
- GDB Vs. WinDbg Commands
- VisualGDB系列8:使用VS创建CMake Linux项目
- GDB: solib-absolute-prefix vs. solib-search-path
- 成功运行过的WinDBG Commands–12-26-2010
- Useful WINDBG commands