您好,欢迎光临本网站![请登录][注册会员]  
文件名称: GDB调试参考手册
  所属分类: Linux
  开发工具:
  文件大小: 2mb
  下载次数: 0
  上传时间: 2019-03-16
  提 供 者: u0131*****
 详细说明:该资源是GDB的调试参考文档,请有需要的自行下载,没有积分的朋友可以找博主索取!Table of Contents Summary of GDB..… Free Software Free Software Needs free documentation Contributors to gdB 3 1 A Sample GDB Session 2 Getting In and Out of GDB 11 2.1 Invoking gdB 2.1.1 Choosing Files 12 2.1.2 Choosing Modes.......... 13 2.1.3 What GDB Does During Startup 16 2.2 Quitting GDB 17 3 Shell co 17 2. 4 Logging o 3 GDB Commands 申非 19 3.1 Command Syntax 3.2 Command Completion 3.3 Getting Help 着着·着鲁香垂,垂 22 4 Running Programs Under GDB 25 4.1 Compiling for Debugging 25 4.2 Starting your PrograM ,,26 4.3 Your Program's arguments 30 4.4 Your Programs Environment 30 4.5 Your Programs Working Directory 31 4.6 Your Program's Input and Output 32 4.7 Debugging an Alrcady-running Proccss 33 4.8 Killing the child process 34 4.9 Debugging Multiple Inferiors and Programs 34 4.10 Debugging Programs with Multiple Threads 37 4.11 Debugging Forks 42 4.12 Setting a Bookmark to Return to Later .44 4.12.1 A Non-obvious Benefit of Using Checkp OInts Debugging with GDB 5 Stopping and Continuing 47 5. 1 Breakpoints, Watchpoints, and Calchpoinls 47 5.1.1 Setting Breakpoints 18 5.1.2 Setting Watchpoints 54 5.1.3 Setting Catchpoints 57 5.1. 4 Deleting Breakpoints ·;···.······ 61 5.1.5 Disabling Breakpoints 62 5.1.6 Break Conditions .63 5.1.7 Breakpoint Command Lists 65 5.1.8 Dynamic Printf 66 5.1.9 How to save breakpoints to a file 68 5.1.10 Static Probe Points 68 5.1.11 Cannot insert breakpoints 70 5.1.12“ Breakpoint address adjusted..” 70 5.2 Continuing and stepping 70 3 Skipping Over Functions and Files 74 5.4 Signals ∴..76 5.5 Stopping and Starting Multi-thread Programs ..80 5.5.1 All-Stop Mode.… 5.5. 2 Non-Stop Mode 81 5.5. 3 Background Execution 82 5.5.4 Thread-Specific Breakpoints............... 83 5.5.5 Interrupted Systeln calls ..84 5.5.6 Observer Mode 84 6 Running programs backward 87 7 Recording Inferiors Execution and Replaying It 89 8 Examining the Stack 97 8.1 Stack frames 鲁鲁, 97 8.2 Backtraces 98 8.3 Selecting a frame ..100 8. 4 Information About a frame 102 8.5 Applying a Command to Several Frames ∴..104 8.6 Management of Frame Filters ..105 9 Examining Source Files .109 9.1 Printing source lines 109 9.2 Specifying a Location · 110 9.2.1 Linespec Locations ,,110 9.2.2 Explicit Locations..……,,111 9.2.3 Address locations ,,,112 9.3 Editing source files 113 9.3. 1 Choosing your Editor 113 9.1 Scarching sourcc files 114 9.5 Specifying Source Directories ····· 114 9. 6 Source and machine code 117 10卫 examining Data.. 申·。·看D 123 10.1 Expressions ....125 10.2 Ambiguous Expressions 126 10.3 Program Varia bles 127 10.4 Artificial Array 130 10.5 Output Formats 130 10.6 Examining Memory 132 10.7 Automatic Display ..134 10.8 Print Settings ··,···· 136 10.9 Pretty Printing ,144 10.9.1 Pretty-Printer Introduction 144 10.9.2 Pretty-Printer Example....... .....144 10.9.3 Pretty-Printer Commands............... 145 10.10 Value Histol 116 10.11 Convenience Variables ..147 10.12 Convenience functions ..119 10.13 Registers 152 10.14 Floating point hardware.................. 154 10.15V 154 10.16 Opcrating System Auxiliary Information 154 10.17 Memory Region Attributes 156 10.17.1 Attributes ∴.,157 10.17.1 1 Memory Access Mode 157 10. 17.1.2 Memory Access Size ∴.157 10.17.1.3 Data Cache 158 10.17.2 Memory Access Checking 158 10.18 Copy Between Memory and a File 158 10. 19 How to Produce a Core File from Your Program...... 159 10.20 Character sets .160 10.21 Caching Data of Targets.................. 163 10.22 Search Memor ...164 10.23 Value sizes 165 11 Debugging Optimized Code ........ 167 11.1 Inline functions ..167 11.2 Tail Call Frames 168 ugging with GDB 12 C Preprocessor Macros 171 13 Tracepoints 175 13.1 Commands to Set tracepoints 175 13.1.1 Create and Delete Tr 176 13. 1.2 Enable and Disable Tracepoints 178 13.1.3 Tracepoint Passcounts 178 13.1.4 Tracepoint Conditions 179 13.1.5 Trace State Variables 179 13.1.6 Tracepoint Action Lists ..180 13. 1.7 Listing Tracepoints 182 13.1. 8 Listing Static Tracepoint Markers 183 13.1.9 Starting and Stopping Trace Ex] ts∴∴,184 13.1.10 Tracepoint restrictions ..,186 13.2 Using the Collected Dala. ∴,,187 13.2.1 tfind n. ∴,,,,,,,187 13.2.2 thump... ,189 13.2.3 save tracepoints filename .190 13.3 Convenience Variables for Tracepoints ....190 13.4 USing Trace Files 191 14 Debugging Programs That Use Overlays 193 14.1 How Overlays Work ∴......193 14.2 Overlay Commands 194 14.3 Automatic Overlay Debugging 196 14.4 Overlay Sample program 197 15 Using GDB with Different Languages 199 15.1 Switching Bctwccn Sourcc Languages .199 15.1.1 List of Filename Extensions and Languages....... 199 15.1.2 Setting the Working language 15.1.3 Having GDB Infer the Source Language 200 15.2 Displaying the language ∴..200 15.3 Type and Range Checking 01 15.3.1 An Overview of Type Checking............ 201 15.3.2 An Overview of Range Checking 202 15.4 Supported languages 03 15.4.1 C and c++ 203 15.4.1.1 C and o++O 03 15.4.1.2 C and C++ Constants ∴.....,,205 15.4. 1.3 C++ Expressions 15.1.1.1C and C++ Defaults 207 15.4.1.5 C and C++ Type and range Checks 07 15.1.1. 6 GDB and c 207 15.4.1.7 GDB Features for c++ 207 15.4.1.8 Decimal Floating Point format 209 15.4.2D 15.4.3Go. ∴.....209 15.4.4 Objective-C .210 15.4.4.1 Method names in Commands ∴.....,210 15.4.4.2 The Print Command With Objective-C ....211 15.4.5 OpenCL C 211 15.4.5. 1 Open CL C Datatypes ,,,,,,,211 15.4.5.2 OpenCL C上 xpressIons.……,,,……,.2l1 15.4.5. 3 OpenCL C operators 15.4.6 Fortran ∴.211 15.4.6.1 Fortran Operators and expressions........212 15.4.6.2 Fortran Defaults 15.4.6.3 Special Fortran Commands 212 15.4.7 Pascal 212 15.4.8Rus 212 15.4.9 Modula-2 ∴213 15.4.9.1 Operators 213 15.4.9.2 Built-in Functions and procedures 15.4.9.3 Constants 216 15.4.9. Modula-2 Types .216 15.4.9.5 Modula-2 Defaults 218 15.4.9.6 Deviations from Standard Modula-2 218 15.4. 9.7 Modula-2 Type and Range Checks 15.498The Operators d 15.4.9.9 GDB and modula-2 15.4.10Ada.. 申鲁·鲁 219 15.4.10.1 Introduction....,.......,,...... 219 15.4.10.2 Omissions from Ada 220 15.410.4 Over loading support for ada…,"、. 15.1.10.3 Addition ns to ada 21 ,,,,223 15.1.10.5 Stopping at the very Beginning 23 15.4.10.6 Ada Exceptions 223 15.4. 10.7 Extensions for Ada Tasks 224 15.4. 10.8 Tasking Support when Debugging Core Files..... 227 15.4.10.9 Tasking Support when using thc R ar profile ........227 15.4.10.10 Ada sct 227 15.4.10.11 Known peculiarities of ada e 228 15.5 Unsupported Languages 229 16 Examining the Symbol Table ..231 Debugging with GDB 17 Altering Execution 243 17.1 Assignment to Variables 243 17.2 Continuing at a Different Address 211 17. 3 Giving your Program a signal ...245 17.1 Returning from a Function ..216 17.5. 1 Calling functions with no debug inIo.,,,.,,......247 17.5 Calling Program Functions 248 17. 6 Patching programs 248 17.7 Compiling and injecting codc in GDB 17.7.1 Compilation options for the compile command..... 250 17.7.2 Caveats when using the compile command ∴..251 17.7.3 Compiler search for the compile command....... 253 1 8 GDB Files .,,,,,,,255 18.1 CoMmands to Specily Files 255 18.2 File caching …∴·..264 18.3 Debugging Information in Separate Files..........264 18.1 Debugging information in a special section 268 18.5 Index files speed Up gdB ,··· 68 18.5.1 Automatic symbol index cache ..269 18.6 Errors Reading Symbol Files 270 18.7 GDB Data files ∴,271 Specifying a Debugging target 273 19.1 Active Targets 273 19.2 Commands for Managing targets ..,,27 19.3 Choosing Target Byte Order 276 20 Debugging Remote Programs ..277 20.1 Connecting to a Remote Target ∴..277 20.1.1 Types of Remote Connections ∴277 20.1.2 Host and Target files 278 20.1.3 Remote Connection Commands 279 20.2 Sending files to a remote system 282 20.3 USing the gdbserver Program 282 20.3.1 Running gdbserver .283 20.3. 1.1 Attaching to a Running Program ...283 20.3. 1.2 TCP port allocation lifecycle of gdbserver 284 20.3. 1.3 Other Command-Line Arguments for gdbserver.. 284 20.3.2 Connecting to gdbserver 285 20.3. 3 Monitor Commands for gdbserver 20.3.4 Tracepoints support in gdbserver........... 286 20.4 Remote Configuration 87 20.5 Implementing a Remote Stub ..293 20.5.1 What the slub can Do for You 20.5.2 What You Must do for the stub 295 20.5. 3 Putting it All Together 296 VIl 21 Configuration-Specific Information 299 21.1 Native..... ..,.299 21.1.1 BSD libkvm Interface 299 21.1.2 Process information 299 21.1.3 Features for Debugging DjCPP Programs 301 21.1.4 Features for Debugging ms Windows Pe executables. 304 21.1.4.1 Support for DlLs without Debugging Symbols... 305 21.1.4.2 DLL Name prefixes .306 21.1.4.3 Working with Minimal Symbols ∴..,,306 21. 1.5 Commands specific to GNU Hurd systems .307 21.1.6 Darwin.…… .....,309 21.1. 7 FreeBSD ...310 21.2 Embedded Operating Systems 310 21.3 Embedded processors ......310 21.3. 1 Synopsys ArC ...310 21.3.2ARM..... .311 21.3.3M68k. 312 21.3.4 Microblaze ..312 21.3.5 MIPS Embedded 313 21.3.6 OpenRIsc 1000 ..313 21.3. 7 PowerPC embedded 313 21.3.8 Atmel AVR ,,314 21.3.9CRIS. ∴.315 21.3.10 Renesas Super-H 315 21.4 Architectures 21.4.1 AArch64. 316 21 4.1.1 AArch64 SVE .,.316 21.4.2 x86 Architccturc-spccific Issues ∴...316 21.4.2. 1 Intel Memory Protection Extensions(MPX).... 316 21.4.3 Alpha 317 21.4.4MTPS 317 21.4.5HPPA. 319 21.4.6 Cell Broadband Engine sPu architecture 21.4.7 PowerPC ..320 21.4.8 NiOS Il ...320 21.4.9 Sparc64 321 21.4.9.1 ADI SU .....321 21.4.10S12Z ..321 ugging with GDB 22 Controlling gDB ..323 22.1 Prompt ...·...·· .323 22.2 Command Editing · ..323 22. 3 Command History 324 22.1 Screen size ..,,,,325 22.5 Output styling 326 22.6 Numbers 327 22.7 Configuring the Current abi 328 22.8 Automatically loading associatcd files 32 2.8.1 Automatically loading init file in the current directory. 331 2.8.2 Automatically loading thread debugging libr 331 22.8. 3 Security restriction for auto-loading 332 22.8.4 Displaying files tried fo or auto-load ∴.334 22.9 Optional Warnings and Messages .....334 22.10 Optional Messages about Internal happenings ....... 335 22.11 Other Miscellaneous Settings 340 23 Extending GDB 341 23.1 Canned Sequences of commands ∴,.341 23.1.1 User-defined commands 341 23.1.2 User-defined command hooks 23. 1.3 Command files .344 23. 1.4 Commands for Controlled output 346 23. 1.5 Controlling auto-loading natiVe GDB scripts 347 23.2 Extending GDB using Python 348 23.2.1 Python Commands.................. 348 23.2.2 Python APi 349 23.2.2.1 Basic Python ..349 23.2.2.2 Exception Handling ...353 23.2.2.3 Values from Inferior 354 23.2.2.4 Tvpes In Python 359 23.2.2.5 Pretty Printing API ∴...363 23.2.2.6 Selecting Pretty-Printers 365 23.2.2.7 Writing a Pretty-Printer ...365 23.2.2.8 Type Printing API 鲁4 ...368 23.2.2.9 Filtering Frames ..368 23.2.2.10 Decorating frames 371 23.2.2. 11 Writing a Fraine Filter 373 23.2.2.12 Unwinding Frames in Python 377 23.2.2. 13 Xmethods In Python. 380 23.2.2.14 Xmethod API 381 23.2.2. 15 Writing an Xmethod............... 382 23.2.2.16 Inferiors In Pith 385 23.2.2. 17 Events In Path 386 23.2.2.18 Thrcads In Python 390 23.2.2.19 Recordings In python 391 23.2.2.20 Commands In python · 395 23.2.2.21 Parameters In Python 398
(系统自动生成,下载前可以参看下载内容)

下载文件列表

相关说明

  • 本站资源为会员上传分享交流与学习,如有侵犯您的权益,请联系我们删除.
  • 本站是交换下载平台,提供交流渠道,下载内容来自于网络,除下载问题外,其它问题请自行百度
  • 本站已设置防盗链,请勿用迅雷、QQ旋风等多线程下载软件下载资源,下载后用WinRAR最新版进行解压.
  • 如果您发现内容无法下载,请稍后再次尝试;或者到消费记录里找到下载记录反馈给我们.
  • 下载后发现下载的内容跟说明不相乎,请到消费记录里找到下载记录反馈给我们,经确认后退回积分.
  • 如下载前有疑问,可以通过点击"提供者"的名字,查看对方的联系方式,联系对方咨询.
 相关搜索: GDB调试参考手册
 输入关键字,在本站1000多万海量源码库中尽情搜索: