Skip to main content

An Efficient Static Trace Simplification Technique for Debugging Concurrent Programs

  • Conference paper
Static Analysis (SAS 2011)

Part of the book series: Lecture Notes in Computer Science ((LNPSE,volume 6887))

Included in the following conference series:

Abstract

One of the major difficulties in debugging concurrent programs is that the programmer usually experiences frequent thread context switches, which perplexes the reasoning process. This problem can be alleviated by trace simplification techniques, which produce the same computation process but with much fewer number of context switches. The state of the art trace simplification technique takes a dynamic approach and does not scale well to large traces, hampering its practicality. We present a static trace simplification approach, SimTrace, that dramatically improves the efficiency of trace simplification through reasoning about the computation equivalence of traces offline. By constructing a dependence graph model of events, our trace simplification algorithm scales linearly to the trace size and quadratic to the number of nodes in the dependence graph. Underpinned by a trace equivalence theorem, we guarantee that the results generated by SimTrace are sound and no dynamic program re-execution is required to validate the trace equivalence. Our experiments show that SimTrace scales well to traces with more than 1M events, making it attractive to practical use.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Mazurkiewicz, A.: Trace theory. In: Rozenberg, G. (ed.) APN 1987. LNCS, vol. 266, Springer, Heidelberg (1987)

    Google Scholar 

  2. Ball, T., Naik, M., Rajamani, S.K.: From symptom to cause: localizing errors in counterexample traces. In: POPL (2003)

    Google Scholar 

  3. Chen, F., Roşu, G.: Parametric and sliced causality. In: Damm, W., Hermanns, H. (eds.) CAV 2007. LNCS, vol. 4590, pp. 240–253. Springer, Heidelberg (2007)

    Chapter  Google Scholar 

  4. Choi, J.-D., Zeller, A.: Isolating failure-inducing thread schedules. In: ISSTA (2002)

    Google Scholar 

  5. Curtis, R., Wittie, L.D.: Bugnet: A debugging system for parallel programming environments. In: ICDCS (1982)

    Google Scholar 

  6. Diekert, V., Rozenberg, G.: The book of traces (1995)

    Google Scholar 

  7. Farzan, A., Madhusudan, P., Sorrentino, F.: Meta-analysis for Atomicity Violations under Nested Locking. In: Bouajjani, A., Maler, O. (eds.) CAV 2009. LNCS, vol. 5643, pp. 248–262. Springer, Heidelberg (2009)

    Chapter  Google Scholar 

  8. Flanagan, C., Freund, S.N.: Atomizer: a dynamic atomicity checker for multithreaded programs. In: POPL (2004)

    Google Scholar 

  9. Fonseca, P., Li, C., Singhal, V., Rodrigues, R.: A study of the internal and external effects of concurrency bugs. In: DSN (2010)

    Google Scholar 

  10. Groce, A., Chaki, S., Kroening, D., Strichman, O.: Error explanation with distance metrics. Int. J. Softw. Tools Technol. Transf. (2006)

    Google Scholar 

  11. Groce, A., Visser, W.: What went wrong: Explaining counterexamples. In: Ball, T., Rajamani, S.K. (eds.) SPIN 2003. LNCS, vol. 2648, pp. 121–135. Springer, Heidelberg (2003)

    Chapter  Google Scholar 

  12. Hower, D.R., Hill, M.D.: Rerun: Exploiting episodes for lightweight memory race recording. In: ISCA (2008)

    Google Scholar 

  13. Huang, J., Liu, P., Zhang, C.: LEAP: Lightweight deterministic multi-processor replay of concurrent Java programs. In: Hong, S., Iwata, T. (eds.) FSE 2010. LNCS, vol. 6147, Springer, Heidelberg (2010)

    Chapter  Google Scholar 

  14. Jalbert, N., Sen, K.: A trace simplification technique for effective debugging of concurrent programs. In: FSE (2010)

    Google Scholar 

  15. Lamport, L.: Time, clocks, and the ordering of events in a distributed system. CACM (1978)

    Google Scholar 

  16. Montesinos, P., Ceze, L., Torrellas, J.: Delorean: Recording and deterministically replaying shared-memory multi-processor execution efficiently. In: ISCA (2008)

    Google Scholar 

  17. Musuvathi, M., Qadeer, S., Ball, T., Basler, G., Nainar, P.A., Neamtiu, I.: Finding and reproducing heisenbugs in concurrent programs. In: OSDI (2008)

    Google Scholar 

  18. O’Callahan, R., Choi, J.-D.: Hybrid dynamic data race detection. In: PPoPP (2003)

    Google Scholar 

  19. Olszewski, M., Ansel, J., Amarasinghe, S.: Kendo: efficient deterministic multithreading in software. In: ASPLOS (2009)

    Google Scholar 

  20. Park, S., Zhou, Y., Xiong, W., Yin, Z., Kaushik, R., Lee, K.H., Lu, S.: PRES: probabilistic replay with execution sketching on multi-processors. In: SOSP (2009)

    Google Scholar 

  21. Şerbănuţă, T.F., Chen, F., Roşu, G.: Maximal causal models for sequentially consistent multithreaded systems. Technical report, University of Illinois (2010)

    Google Scholar 

  22. Sinha, N., Wang, C.: Staged concurrent program analysis. In: FSE (2010)

    Google Scholar 

  23. Tallam, S., Tian, C., Gupta, R., Zhang, X.: Enabling tracing of long-running multithreaded programs via dynamic execution reduction. In: ISSTA (2007)

    Google Scholar 

  24. Vineet, K., Chao, W.: Universal causality graphs: A precise happens-before model for detecting bugs in concurrent programs. In: Touili, T., Cook, B., Jackson, P. (eds.) CAV 2010. LNCS, vol. 6174, pp. 434–449. Springer, Heidelberg (2010)

    Chapter  Google Scholar 

  25. Wang, C., Chaudhuri, S., Gupta, A., Yang, Y.: Symbolic pruning of concurrent program executions. In: ESEC/SIGSOFT FSE (2009)

    Google Scholar 

  26. Wang, C., Limaye, R., Ganai, M., Gupta, A.: Trace-based symbolic analysis for atomicity violations. In: Esparza, J., Majumdar, R. (eds.) TACAS 2010. LNCS, vol. 6015, pp. 328–342. Springer, Heidelberg (2010)

    Chapter  Google Scholar 

  27. Wang, H., He, H., Yang, J., Yu, P.S., Yu, J.X.: Dual labeling: Answering graph reachability queries in constant time. In: ICDE (2006)

    Google Scholar 

  28. Zeller, A., Hildebrandt, R.: Simplifying and isolating failure-inducing input. IEEE Trans. Softw. Eng. (2002)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2011 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Huang, J., Zhang, C. (2011). An Efficient Static Trace Simplification Technique for Debugging Concurrent Programs. In: Yahav, E. (eds) Static Analysis. SAS 2011. Lecture Notes in Computer Science, vol 6887. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-23702-7_15

Download citation

  • DOI: https://doi.org/10.1007/978-3-642-23702-7_15

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-642-23701-0

  • Online ISBN: 978-3-642-23702-7

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics