
Mozilla Fast Debugger with Recording and Playback

RR is designed to accurately reproduce bugs that manifest themselves unpredictably. In such cases, when debugging with standard tools, it makes no sense to run the program again: it is not a fact that the bug will again appear. This problem constantly spoils the life of developers. That's why Mozilla decided to create such a framework.
RR takes debugging to a new level: before leaving for lunch, leave the script for tests with different parameters, and RR will write at least one execution with an error when you return. You can scroll through this entry and understand what the problem is.
Theoretically, GDB is also capable of rewinding program execution, but in reality, this function in RR is implemented an order of magnitude better. The main thing is that we managed to solve the performance problem: the program plays at almost the same speed as normal execution, because RR records only changing fragments and does not touch most of the program.
The diagram shows how different the recording speed and playback speed of the recorded program from its native execution (overhead).

The relatively large overhead reftest is explained by the fact that the current configuration of Gecko for Linux works through the X server
Unfortunately, so far the debugger only supports x86 32-bit processes, but this limitation will probably be removed in future versions. Another limitation of the first version is the emulation of only a single-core machine. For recording parallel computing, you can’t do without hardware support, so you won’t get rid of this limitation so easily. And yet, the debugger so far only works on Intel Ivy Bridge and Sandy Bridge processors.
The creation of the debugging tool RR 1.0 took two years from the Mozilla developers. Github code .