Proceedings of the XXth Conference of Open Innovations Association FRUCT (Apr 2016)
Platform-independent reverse debugging of the virtual machines
Abstract
Prototyping and debugging of operating systems and drivers are very tough tasks because of hardware volatility, kernel panics, blue screens of death, long periods of time required to expose the bug, perturbation of the drivers by the debugger, and non-determinism of multi-threaded environment. This paper shows how the deterministic replay of the virtual machine execution can be used to reduce the impact of these factors to the process of debugging. We present an approach to reverse debugging which allows creating multi-target whole-system debugger. Using this debugger one can investigate the failures affecting behavior of virtual hardware and guest software. Our debugger is capable of replaying whole virtual machine execution with reproducing internal state of all virtual devices. Although reverse debugging was a subject of many previous researches, there is no widely available practical tool for debugging software on different platforms. We present reverse debugger as a practical tool, which was tested for Í386, x86-64, MIPS, and ARM platforms, for Windows and Linux guest operating systems. One can use this debugger to debug user-and kernel-level code, deterministic functional modelling of peripheral devices and hardware platforms. We show that this tool incurs 15-40% recording overhead, which allows using our tool for debugging time-sensitive applications. We presented reverse execution implementation as a set of patches. Some of the patches were already included into mainline QEMU.
Keywords