zoukankan      html  css  js  c++  java
  • Debugging with GDB (6) gdb 命令

    1. 回车重复。 windbg也实现了。shell不可能实现。(有些命令不支持,比如run,因为不能支持)
    2. 支持Tab自动完成,跟shell一样。命令和symbol都支持。
        <ESC> followed by ?. 可以打印出所有可能。比如输入info 然后<ESC> followed by ?
        (gdb) inf
        inferior  info
        还能支持结构成员变量扩展
    3. 命令可以接参数,比如step 5
    4. 命令只要没有二义就不用写全。 更有甚者(这样的设计很好),有二义也有二义的优先级,比如s就指的是step
    5. Getting Help
        help
        h
        help class
            e.g. help status
        help command
            e.g. help step
        apropos args
            打印出所有可能,包括文档
            apropos alias
        complete args
            以args开头的命令,不同于apropos
        info
        set
            set prompt $
        show
    Example:

     1 (gdb) show radix
     2 Input and output radices set to decimal 10, hex a, octal 12.
     3 (gdb) apropos radix
     4 set input-radix -- Set default input radix for entering numbers
     5 set output-radix -- Set default output radix for printing of values
     6 set radix -- Set default input and output number radices
     7 show input-radix -- Show default input radix for entering numbers
     8 show output-radix -- Show default output radix for printing of values
     9 show radix -- Show the default input and output number radices
    10 (gdb) set input-radix 2
    11 Input radix now set to decimal 2, hex 2, octal 2.
    12 (gdb) show radix
    13 Input radix set to decimal 2, hex 2, octal 2.
    14 Output radix set to decimal 10, hex a, octal 12.
  • 相关阅读:
    Entity Framework 教程
    C# yield
    表达式树系列文章汇总
    C#中静态与非静态方法比较
    谈谈对Spring IOC的理解
    工厂方法模式与IoC/DI
    通过配置的方式Autofac 《第三篇》
    Autofac 组件、服务、自动装配 《第二篇》
    Autofac 解释第一个例子 《第一篇》
    SQL Server索引调优系列
  • 原文地址:https://www.cnblogs.com/xjsllll/p/2987328.html
Copyright © 2011-2022 走看看