skip to main content
research-article

Reusing debugging knowledge via trace-based bug search

Published:19 October 2012Publication History
Skip Abstract Section

Abstract

Some bugs, among the millions that exist, are similar to each other. One bug-fixing tactic is to search for similar bugs that have been reported and resolved in the past. A fix for a similar bug can help a developer understand a bug, or even directly fix it. Studying bugs with similar symptoms, programmers may determine how to detect or resolve them. To speed debugging, we advocate the systematic capture and reuse of debugging knowledge, much of which is currently wasted. The core challenge here is how to search for similar bugs. To tackle this problem, we exploit semantic bug information in the form of execution traces, which precisely capture bug semantics. This paper introduces novel tool and language support for semantically querying and analyzing bugs. We describe OSCILLOSCOPE, an Eclipse plugin, that uses a bug trace to exhaustively search its database for similar bugs and return their bug reports. OSCILLOSCOPE displays the traces of the bugs it returns against the trace of the target bug, so a developer can visually examine the quality of the matches. OSCILLOSCOPE rests on our bug query language (BQL), a flexible query language over traces. To realize OSCILLOSCOPE, we developed an open infrastructure that consists of a trace collection engine, BQL, a Hadoop-based query engine for BQL, a trace-indexed bug database, as well as a web-based frontend. OSCILLOSCOPE records and uploads bug traces to its infrastructure; it does so automatically when a JUnit test fails. We evaluated OSCILLOSCOPE on bugs collected from popular open-source projects. We show that OSCILLOSCOPE accurately and efficiently finds similar bugs, some of which could have been immediately used to fix open bugs.

References

  1. B. Ashok, J. Joy, H. Liang, S. Rajamani, G. Srinivasa, and V. Vangala. DebugAdvisor: A recommender system for debugging. In Proceedings of the 17th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT International Symposium on the Foundations of Software Engineering, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. I. Beer, S. Ben-David, H. Chockler, A. Orni, and R. Trefler. Explaining counterexamples using causality. In Proceedings of the International Conference on Computer Aided Verification, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. N. Bettenburg, S. Just, A. Schröter, C. Weiss, R. Premraj, and T. Zimmermann. What makes a good bug report? In Proceedings of the 16th ACM SIGSOFT International Symposium on the Foundations of Software Engineering, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. P. Dhoolia, S. Mani, V. S. Sinha, and S. Sinha. Debugging model-transformation failures using dynamic tainting. In Proceedings of the 24th European Conference on Object-Oriented Programming, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. D. R. Engler, D. Y. Chen, and A. Chou. Bugs as inconsistent behavior: A general approach to inferring errors in systems code. In Proceedings of the ACM Symposium on Operating Systems Principles, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. S. Goldsmith, R. O'Callahan, and A. Aiken. Relational queries over program traces. In Proceedings of the 20th Annual ACM SIGPLAN Conference on Object-Oriented Programming, Systems, Languages, and Applications, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. A. Groce, S. Chaki, D. Kroening, and O. Strichman. Error explanation with distance metrics. International Journal on Software Tools for Technology Transfer, 8(3):229--247, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. A. Groce and W. Visser. What went wrong: Explaining counterexamples. In SPIN Workshop on Model Checking of Software, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. Z. Gu, E. Barr, and Z. Su. BQL: Capturing and reusing debugging knowledge. In Proceedings of the 33rd International Conference on Software Engineering (Demo Track), 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. D. Gusfield. Algorithms on Strings, Trees, and Sequences: Computer Science and Computational Biology. Cambridge University Press, 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. B. Hartmann, D. MacDougall, J. Brandt, and S. R. Klemmer. What would other programmers do: Suggesting solutions to error messages. In Proceedings of the 28th International Conference on Human Factors in Computing Systems, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. K. Hoffman, P. Eugster, and S. Jagannathan. Semantics-aware trace analysis. In Proceedings of the 2009 ACM SIGPLAN Conference on Programming Language Design and Implemen-tation, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. E. W. Host and B. M. Ostvold. Debugging method names. In Proceedings of the 23rd European Conference on Object-Oriented Programming, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. J. A. Jones, M. J. Harrold, and J. Stasko. Visualization of test information to assist fault localization. In Proceedings of the 24th International Conference on Software Engineering, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. H. Jula, D. Tralamazza, C. Zamfir, and G. Candea. Deadlock immunity: Enabling systems to defend against deadlocks. In Proceedings of the 8th USENIX Conference on Operating Systems Design and Implementation, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. S. Kim, K. Pan, and E. J. Whitehead, Jr. Memories of bug fixes. In Proceedings of the 14th ACM SIGSOFT International Symposium on Foundations of Software Engineering, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. A. Ko and B. Myers. A framework and methodology for studying the causes of software errors in programming systems. Journal of Visual Languages & Computing, 16(1-2):41--84, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. J. R. Larus. Whole program paths. In Proceedings of the 1999 ACM SIGPLAN Conference on Programming Language Design and Implementation, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. B. Liblit. Cooperative Bug Isolation. Springer-Verlag, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. B. Liblit, A. Aiken, A. Zheng, andM. Jordan. Bug isolation via remote program sampling. In Proceedings of the 2003 ACM SIGPLAN Conference on Programming Language Design and Implementation, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. B. Liblit, M. Naik, A. Zheng, A. Aiken, and M. Jordan. Scalable statistical bug isolation. In Proceedings of the 2005 ACM SIGPLAN Conference on Programming Language Design and Implementation, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. M. Martin, B. Livshits, and M. S. Lam. Finding application er-rors and security flaws using PQL: A program query language. In Proceedings of the ACM Conference on Object-Oriented Programming, Systems, Languages, and Applications, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. T. T. Nguyen, H. A. Nguyen, N. H. Pham, J. Al-Kofahi, and T. N. Nguyen. Recurring bug fixes in object-oriented programs. In Proceedings of the 32nd International Conference on Software Engineering, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. K. Olender and L. Osterweil. Cecil: A sequencing constraint language for automatic static analysis generation. IEEE Transactions on Software Engineering, 16(3):268--280, 1990. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. G. Pothier and E. Tanter. Summarized trace indexing and query-ing for scalable back-in-time debugging. In Proceedings of the 25th European Conference on Object-Oriented Programming, 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. G. Pothier, E. Tanter, and J. Piquer. Scalable omniscient debug-ging. In Proceedings of the 22nd ACM SIGPLAN Conference on Object-Oriented Programming, Systems, Languages, and Applications, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. P. Runeson, M. Alexandersson, and O. Nyholm. Detection of duplicate defect reports using natural language processing. In Proceedings of the 29th International Conference on Software Engineering, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  28. A. Schröter, N. Bettenburg, and R. Premraj. Do stack traces help developers fix bugs? In Proceedings of the 7th IEEE Working Conference on Mining Software Repositories, 2010.Google ScholarGoogle ScholarCross RefCross Ref
  29. X. Wang, L. Zhang, T. Xie, J. Anvik, and J. Sun. An approach to detecting duplicate bug reports using natural language and execution information. In Proceedings of the 30th International Conference on Software Engineering, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. W. Weimer, T. Nguyen, C. L. Goues, and S. Forrest. Automatically finding patches using genetic programming. In Proceedings of the 31st International Conference on Software Engineering, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. A. Zeller. Yesterday, my program worked. Today, it does not. Why? In Proceedings of the 7th ACM SIGSOFT International Symposium on the Foundations of Software Engineering, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. X. Zhang, N. Gupta, and R. Gupta. Locating faults through automated predicate switching. In Proceedings of the 28th International Conference on Software Engineering, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Reusing debugging knowledge via trace-based bug search

            Recommendations

            Comments

            Login options

            Check if you have access through your login credentials or your institution to get full access on this article.

            Sign in

            Full Access

            • Published in

              cover image ACM SIGPLAN Notices
              ACM SIGPLAN Notices  Volume 47, Issue 10
              OOPSLA '12
              October 2012
              1011 pages
              ISSN:0362-1340
              EISSN:1558-1160
              DOI:10.1145/2398857
              Issue’s Table of Contents
              • cover image ACM Conferences
                OOPSLA '12: Proceedings of the ACM international conference on Object oriented programming systems languages and applications
                October 2012
                1052 pages
                ISBN:9781450315616
                DOI:10.1145/2384616

              Copyright © 2012 ACM

              Publisher

              Association for Computing Machinery

              New York, NY, United States

              Publication History

              • Published: 19 October 2012

              Check for updates

              Qualifiers

              • research-article

            PDF Format

            View or Download as a PDF file.

            PDF

            eReader

            View online with eReader.

            eReader
            About Cookies On This Site

            We use cookies to ensure that we give you the best experience on our website.

            Learn more

            Got it!