Home | english  | Impressum | KIT

Towards Heterogeneous Record and Replay on the ARM Architecture

Towards Heterogeneous Record and Replay on the ARM Architecture
Typ:Masterarbeit
Datum:31.01.2017
Betreuer:

Prof. Dr. Frank Bellosa
Marc Rittinghaus

Bearbeiter:Simon Veith
Links:PDF

Abstract:

Record and replay is a technique that enables full-system debugging at high execution speeds. During execution of a virtual machine, all non-deterministic input to the system is saved to a log file. Later, this log file can be used to feed the recorded data back into another virtual machine instance to reproduce the exact execution as in the original system, accurate to the instruction level. Examining a system’s operation on an instruction-by-instruction basis with little runtime overhead enables more insights for the purpose of software verification or security analysis, particularly with regard to the mobile devices and server markets.

While the ARM architecture has been gaining in popularity during the past decade, and the software running on such machines has greatly increased in complexity, most work in the field of record and replay has thus far focused on the x86 architecture. A deterministic record and replay implementation for ARM exists, recording non-deterministic inputs at the virtual device level, but it does not support hardware virtualization.

This work evaluates the feasibility of a heterogeneous record and replay solution for the ARMv7 architecture. We identify the sources of non-determinism in an ARM computer system and demonstrate our implementation of a low-level record and replay scheme with QEMU. Our modified virtual machine software can successfully perform homogeneous record and replay of unmodified guests using the Tiny Code Generator (TCG) binary translator.

We have implemented recording for the heterogeneous case, using the Linux Kernel-based Virtual Machine (KVM) as the hypervisor. However, we have identified several issues in the architecture’s design and its implementations that complicate a successful replay: Certain instructions exhibit non-deterministic behavior that cannot be recorded; however, with appropriate correction mechanisms, successful replay may yet be possible.

Although runtime overheads of up to 40 % have been observed in the KVM-accelerated recording system, it still operates faster than a TCG-based virtual machine running on high-end x86 machines.

Bibtex:

@mastersthesis{veith17rnr,
  author = {Simon Veith},
  title = {Towards Heterogeneous Record and Replay on the ARM Architecture},
  type = {Master Thesis},
  year = 2017,
  month = jan # "31",
  school = {Operating Systems Group, Karlsruhe Institute of Technology (KIT), Germany}
}