Font Size: a A A

Design And Implementation Of Reversible Debugger For Embedded Systems

Posted on:2010-11-09Degree:MasterType:Thesis
Country:ChinaCandidate:Y WangFull Text:PDF
GTID:2178330332488560Subject:Computer software and theory
Abstract/Summary:PDF Full Text Request
With the increasing complexity of embedded systems, debugging gains more and more importance and attention from the embedded systems developers. Traditional cyclic debugging is insufficient to debug the non-deterministic systems, such as embeded operating systems, parallel programs. Reversible debugging can address those problems associated with debugging non-deterministic systems. Logging and replaying based reverse execution allows a programmer to navigate backward through the execution history and replay the historic execution path. So the programmer can locate the cause of the failure soon, avoid repeated cyclic debugging and can replay the failure scenario exactly.Based on the open source simulator QEMU and debugger GDB, this paper designs and implementes a reversible debugger referred to as PORD, which provides a cross-platform reversible debugger for embedded systems. It enables the embedded systems in ARM, SPARC, PPC or MIPS instruction set architectures to be debugged on a general-purpose X86 host architecture. Program state mainly consists of registers state and memory state. To the registers state recording, PORD uses different methods for different target architectures. However, this paper uses a unified method to record the memory state for different target architectures. In order to reduce time and space overheads for logging execution trace, checkpoints can be recorded at different levels of granularity. PORD also implements an efficient reversible debugger for X86 target architecture, which enjoys a near native speed.PORD mainly includes two components. One is virtual machine achieving logging and replaying capacity by modifying QEMU. The other one is RGDB realized by integrating reverse execution commands into the general-purpose debugger GDB. RGDB interprets the user commands and sends the command packages to the GDB-Stub via Remote Serial Protocol. GDB-Stub in the virtual machine side is responsible for interpreting the debugging command packages and controlling the virtual machine to execute corresponding actions.The evaluation shows that PORD can replay program's historic execution path fast and efficiently. The space and time overheads needed to support reverse execution are reasonable for debugging.
Keywords/Search Tags:embedded systems, virtual machine, reversible debugging, QEMU
PDF Full Text Request
Related items