Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-25967

Improve stack traces provided by mongosymb.py

    • Type: Icon: Improvement Improvement
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 3.3.14
    • Affects Version/s: None
    • Component/s: Diagnostics
    • Minor Change
    • v3.2
    • Repl 2016-09-19

      This ticket covers two changes to mongosymb.py:

      • Include the column number and a trailing colon in the default output format. This matches compiler error formats so makes it easier for off-the-shelf tools such as vim to consume the output.
      • Subtract 1 from each address in the stack trace. This puts the addresses inside the 'call' instruction rather than on the return address (which is the instruction right after the call). This leads to more accurate stack traces in the common case where function calls are involved. The downside is that instructions which raise a signal (such as segfaults or divide by zero) were correct but will now also be adjusted to point to the instruction before. This is considered a worthwhile trade-off because the stack leading up to the signal and the full stack for other stack traces such as invariant failures will now be correct.

            Assignee:
            mathias@mongodb.com Mathias Stearn
            Reporter:
            mathias@mongodb.com Mathias Stearn
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: