We present a temporal debugger, capable of examining time flow of
applications in general-purpose computer systems. The debugger is
attached to a simulator modelling an entire workstation in sufficient
detail to run commodity operating systems and workloads. Whereas
traditional debuggers need to interfere with program execution,
thereby changing the temporal behaviour, a debugger operating on a
simulated system does not disturb the timing of the target program.
The temporal debugger provides reproducible experiments and supports
large amounts of instrumentation and monitoring without intrusion. It
is therefore an excellent platform for testing, debugging, and
profiling time-sensitive programs, such as multimedia applications.
We have implemented the temporal debugger by modifying the GNU
debugger to operate on applications running in a simulated Linux
system. Debugger implementation is difficult because the debugger
expects application-related data, whereas the simulator provides
low-level data. We introduce a technique, virtual machine translation,
for mapping simulator data to the debugger by parsing operating system
data structures in the simulated system.
The debugger environment allows execution time measurement and
collection of performance statistics from multiple levels of the
simulated system: hardware, operating system, and application level.
We show how this data can be used to profile quality of service
performance of an MPEG video decoder. The debugger is used to detect
display jitter, occurring when the decoder fails to render frames in
time. By correlating runtime statistics to image rendering time, we
expose deviations when the application is unable to render an image in
time, thereby locating the cause of the display jitter.