• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            隨筆-4  評論-40  文章-117  trackbacks-0

             

            文章出處:DIY部落(http://www.diybl.com/course/3_program/c++/cppsl/2008825/137412.html#)

             

            gdb用法比較多,功能很強大,平時用到的命令大概二十條,因為一些原因,好久沒用了,都生疏了。

            昨天花了半天總結(jié)一下,詳細信息還是在gdb中用help看。有點亂,網(wǎng)上好像沒有思維導(dǎo)圖,等有時間

            freemind做個,如有錯誤,還請指正!

            ========================================================

            基于命令行的GDB前端:gdb

            基于圖形的GDB前端:DDD xxgdb

            基于文本的GDB前端 gdbtui|gdb -tui

             

            .gdb命令行參數(shù):

             

            gdb (gdb arguments)--args myprog (myprog arguments)

            gdb myprog -tty /dev/pts/1 [注:此處是-tty,并非有些參考書上寫的-t)

            gdb -q(-s)   :do not display the gdb and GPL information

            gdb -batch -x command_file myprog :usefel!

             

            .進入gdb后的命令:

               1. file : load the execute file if not load in the command line

               2. shell shell_command Execute the rest of the line as a shell command.With no arguments, run an inferior shell.

               3. 怎樣不退出gdb編輯,編譯源文件并重新加載編譯后的? kill

               4.

             

               5.

             

             

               6. l(ist) [from,to] repeat to display the whole source code

               7.

             

               8. b(reak)   (num or function) if condition

               9. condition bp_number [expression]    if u have set bp in the desired position, add or change the the bk condition

             10.                                     To delete a break condition,do not use expression

             11. watch

             12. watch expression     stop the program when the value of expression changes.

             13. rwatch expression    stop the program whenever the program reads the value of any object involved in the evaluation of ex                     pression.

             14. awatch expression    stop the program whenever the program reads or modifies the value of any object involved in the eval                     uation of expression.

             15. delete

             16. enable

             17. disable

             18. ignore N n        ignore bp N n times

             19.

             

             20. r(un)

             21. s(tep) [lines] finish

             22. n(ext) [lines]

             23. c(ontinue) [passes]        pass the bp passes times before stop the program

             24.

             

             25. display

             26. p(rint)[/format] [expression]

             27. /format=/d u x o t c|a f

             28. x[/nfu] [address]

             29. /nfu

             30. n: how many units,default is one

             31. u the size of one unit the value is b h w g

             32. f = the print format in additional to s and i

             33. f = d u x o t f c s a i

             34. ptyp(=whatis)

             35.

             

             36.

             

             

             37. bt(backtrace)(=where)

             38. frame display and change the current frame

             39. info (frame.....) :display the information of the program

             40. show               :display the information of gdb

             41.

             

             42. set args    set env VAR1=test set variable

             43. show args   show env

             44.

             

             45. call

             46. disassemble

             47. until

             48. attach

            posted on 2010-03-03 18:32 李陽 閱讀(422) 評論(0)  編輯 收藏 引用

            只有注冊用戶登錄后才能發(fā)表評論。
            網(wǎng)站導(dǎo)航: 博客園   IT新聞   BlogJava   博問   Chat2DB   管理


            精品一区二区久久久久久久网站| 久久精品欧美日韩精品| 无码国内精品久久综合88| AV无码久久久久不卡蜜桃| 亚洲国产成人久久笫一页| 亚洲国产成人久久综合野外| 国产一区二区三精品久久久无广告| 日韩精品久久久肉伦网站 | 国产精品久久久久久久久鸭| 奇米影视7777久久精品人人爽| 久久黄视频| 久久精品国产亚洲综合色| 久久精品99久久香蕉国产色戒| 1000部精品久久久久久久久| 久久精品午夜一区二区福利| 热re99久久精品国99热| 色88久久久久高潮综合影院| 久久亚洲精品国产精品| 久久久久免费看成人影片| 久久亚洲国产午夜精品理论片 | 91精品观看91久久久久久| 99精品久久久久久久婷婷| 久久99精品久久久久久秒播| 性做久久久久久久久| 中文精品99久久国产| 中文字幕无码免费久久| 久久天天躁狠狠躁夜夜96流白浆 | 香蕉久久夜色精品国产小说| 久久久久国产精品麻豆AR影院| 久久久无码精品午夜| 2021国产精品久久精品| 99久久精品国产麻豆| 亚洲欧美日韩久久精品| 狠狠色丁香婷综合久久| 人人狠狠综合久久亚洲| 亚洲精品无码成人片久久| 久久精品国产只有精品2020| 亚洲午夜无码AV毛片久久| 免费国产99久久久香蕉| 久久精品国产99久久久古代| 精品99久久aaa一级毛片|