Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-9287

Add auto loading to GDB functions

    • Storage Engines
    • 5
    • StorEng - Defined Pipeline

      Summary
      Some GDB helper functions were added as part of WT-8158. They would be more useful if it were easy to auto-load them in GDB. A starting point is the wrapper tools/gdb/gdb.wt script that loads the other files in the directory. It does that via manually sourcing them, which isn't efficient or extensible.

      We should look for ways to have the GDB functions auto-loaded when launching WiredTiger in GDB (or attaching). The documentation makes it seem as though that is possible. A first stage will involve creating a .gdbinit file which loads the default WiredTiger gdb scripts.

      Motivation
      GDB is part of every WiredTiger developers life - making our experience with it better and more consistent is a win to developer productivity.

      Testing
      Test that the auto-load solution works, and ask others on the team to try it out as well.

      Documentation update
      Describe in a comment somewhere the environment(s) on which auto-loading works and how to set it up.

      Scope:

      • Create a .gdbinit file which loads WiredTiger's gdb scripts.
        • dump_insert_list.py
        • dump_row_int.gdb
        • wt_debug_script_update.py
      • Add it to the repository under tools/gdb.
      • If the spawnhost work is complete WT-11666 then also deploy the script to the correct location, or create a follow up ticket. Otherwise mention on that ticket that the .gdbinit file has been created.

            Assignee:
            andrew.morton@mongodb.com Andrew Morton
            Reporter:
            alexander.gorrod@mongodb.com Alexander Gorrod
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: