ONTRAC: A system for efficient ONline TRACing for debugging

V. Nagarajan, D. Jeffrey, R. Gupta, Neelam Gupta

Research output: Chapter in Book/Report/Conference proceedingConference contribution


Dynamic slicing is a promising trace based technique that helps programmers in the process of debugging. In order to debug a failed run, dynamic slicing requires the dynamic dependence graph (DDG) information for that particular run. In prior work, address and control-flow traces are collected online and then extensively post-processed offline to yield the DDG, upon which slicing is performed. Unfortunately, the offline post-processing step can be extremely time consuming [21], impeding the use of dynamic slicing as a debugging technique. In this paper, we present ONTRAC, an efficient online tracing system, that directly computes the dynamic dependences online, thus eliminating the expensive offline postprocessing step. To minimize the program slowdown, we make the design decision of not outputting the computed dependences to a file, instead storing them in memory in a specially allocated fixed size circular buffer. The size of the buffer limits the length of the execution history that can be stored. To maximize the execution history that can be maintained, we introduce optimizations to eliminate the storage of most of the generated dependences, at the same time ensuring that those that are stored are sufficient to capture the bug. Our experiments conducted with real bugs confirm the above fact. Other experiments conducted on cpu-intensive programs show that our optimizations are able to reduce the trace-rate from 16 bytes to 0.8 bytes per executed instruction. This enables us to store the dependence trace history for a window of 20 million executed instructions in a 16 MB buffer. ONTRAC is also very efficient, only slowing down the execution by a factor of 19, eliminating the slowdown by a factor of 540 due to post-processing.
Original languageEnglish
Title of host publicationSoftware Maintenance, 2007. ICSM 2007. IEEE International Conference on
Number of pages10
ISBN (Electronic)978-1-4244-1256-3
Publication statusPublished - 1 Oct 2007


  • program debugging
  • program slicing
  • debugging process
  • dynamic dependence graph information
  • dynamic slicing
  • online tracing system
  • Buffer storage
  • Computer bugs
  • Computer science
  • Debugging
  • History
  • Impedance
  • Productivity
  • Programming profession


Dive into the research topics of 'ONTRAC: A system for efficient ONline TRACing for debugging'. Together they form a unique fingerprint.

Cite this