Recently, I started to use reverse debugging with gdb in C++ and it works pretty well for certain types of problems (e.g., loops and recursive algorithms). Besides gdb, there are other commercial debuggers for C/C++ (e.g., UndoDB).
I wonder if there are good reversible debuggers for other languages?
I’m especially interested in Java and Ruby but the question is open to any language.
An alternative that I found is to run your application on a virtual machine and connect to it. The only implementation that I know of (but never tested) is VMware’s Replay Debugging. I wonder for which types of debugging tasks it is suitable. Seems to be overkill for most common problems but it may be useful to debug communication or synchronization issues, which are generally hard to reproduce.
Background information:
- The term “Reverse Debugging” is used by gdb. However, there are many synonyms:
- “Reversible Debugging”
- Microsoft calls it IntelliTrace or “Historical Debugging”
- In Java, such debuggers are sometimes known as an “Ominiscient Debugger”
- (on programmers.stackexchange) Why is reverse debugging rarely used?
In Why is reverse debugging rarely used? (on programmers.stackexchange), Jakob Engblom posted a great summary on the current state of reverse debugging: