skip to main content
research-article

A randomized dynamic program analysis technique for detecting real deadlocks

Authors Info & Claims
Published:15 June 2009Publication History
Skip Abstract Section

Abstract

We present a novel dynamic analysis technique that finds real deadlocks in multi-threaded programs. Our technique runs in two stages. In the first stage, we use an imprecise dynamic analysis technique to find potential deadlocks in a multi-threaded program by observing an execution of the program. In the second stage, we control a random thread scheduler to create the potential deadlocks with high probability. Unlike other dynamic analysis techniques, our approach has the advantage that it does not give any false warnings. We have implemented the technique in a prototype tool for Java, and have experimented on a number of large multi-threaded Java programs. We report a number of previously known and unknown real deadlocks that were found in these benchmarks.

References

  1. R. Agarwal, L. Wang, and S. D. Stoller. Detecting potential deadlocks with static analysis and runtime monitoring. In Parallel and Distributed Systems: Testing and Debugging 2005, 2005.Google ScholarGoogle Scholar
  2. C. Artho and A. Biere. Applying static analysis to large-scale, multi-threaded Java programs. In Proceedings of the 13th Australian Software Engineering Conference (ASWEC'01), pages 68--75, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. S. Bensalem, J.-C. Fernandez, K. Havelund, and L. Mounier. Confirmation of deadlock potentials detected by runtime analysis. In PADTAD'06, pages 41--50, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. S. Bensalem and K. Havelund. Scalable dynamic deadlock analysis of multi-threaded programs. In Parallel and Distributed Systems: Testing and Debugging 2005 (PADTAD'05), 2005.Google ScholarGoogle Scholar
  5. C. Boyapati, R. Lee, and M. Rinard. Ownership types for safe programming: preventing data races and deadlocks. In 17th ACM SIGPLAN Conference on Object-Oriented Programming, Systems, Languages, and Applications, pages 211--230, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. S. Chaki, E. Clarke, J. Ouaknine, N. Sharygina, and N. Sinha. Concurrent software verification with states, events, and deadlocks. Formal Aspects of Computing, 17(4):461--483, 2005.Google ScholarGoogle ScholarCross RefCross Ref
  7. C. Demartini, R. Iosif, and R. Sisto. A deadlock detection tool for concurrent java programs. Software -- Practice and Experience, 29(7):577--603, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. O. Edelstein, E. Farchi, Y. Nir, G. Ratsaby, , and S. Ur. Multithreaded Java program test generation. IBM Systems Journal, 41(1):111--125, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. D. R. Engler and K. Ashcraft. Racerx: effective, static detection of race conditions and deadlocks. In 19th ACM Symposium on Operating Systems Principles (SOSP), pages 237--252, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. C. Flanagan, K. R. M. Leino, M. Lillibridge, G. Nelson, J. B. Saxe, and R. Stata. Extended static checking for java. In PLDI'02: Proceedings of the ACM SIGPLAN 2002 Conference on Programming language design and implementation, pages 234--245. ACM, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. P. Godefroid. Model checking for programming languages using verisoft. In 24th Symposium on Principles of Programming Languages, pages 174--186, 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. J. Harrow. Runtime checking of multithreaded applications with visual threads. In 7th International SPIN Workshop on Model Checking and Software Verification, pages 331--342, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. K. Havelund. Using runtime analysis to guide model checking of java programs. In 7th International SPIN Workshop on Model Checking and Software Verification, pages 245--264, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. K. Havelund and T. Pressburger. Model Checking Java Programs using Java PathFinder. Int. Journal on Software Tools for Technology Transfer, 2(4):366--381, 2000.Google ScholarGoogle ScholarCross RefCross Ref
  15. G. Holzmann. The Spin model checker. IEEE Transactions on Software Engineering, 23(5):279---295, 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. P. Joshi, M. Naik, C.-S. Park, and K. Sen. An extensible active testing framework for concurrent programs. In 21st International Conference on Computer Aided Verification (CAV'09), Lecture Notes in Computer Science. Springer, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. H. Jula, D. Tralamazza, C. Zamfir, and G. Candea. Deadlock immunity: Enabling systems to defend against deadlocks. In Proceedings of the 8th USENIX Symposium on Operating Systems Design and Implementation (OSDI'08), 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. L. Lamport. Time, clocks, and the ordering of events in a distributed system. Commun. ACM, 21(7):558--565, 1978. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. S. Masticola. Static detection of deadlocks in polynomial time. PhD thesis, Rutgers University, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. A. Milanova, A. Rountev, and B. Ryder. Parameterized object sensitivity for points-to analysis for Java. ACM Transactions on Software Engineering and Methodology, 14(1):1--41, Jan. 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. M. Naik, C.-S. Park, K. Sen, and D. Gay. Effective static deadlock detection. In 31st International Conference on Software Engineering (ICSE'09). IEEE, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. Y. Nir-Buchbinder, R. Tzoref, and S. Ur. Deadlocks: From exhibiting to healing. In 8th Workshop on Runtime Verification, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. C.-S. Park and K. Sen. Randomized active atomicity violation detection in concurrent programs. In 16th International Symposium on Foundations of Software Engineering (FSE'08). ACM, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. F. Qin, J. Tucek, J. Sundaresan, and Y. Zhou. Rx: treating bugs as allergies -- a safe method to survive software failures. In SOSP'05: Proceedings of the twentieth ACM symposium on Operating systems principles, pages 235--248. ACM, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. K. Sen. Race directed random testing of concurrent programs. In ACM SIGPLAN Conference on Programming Language Design and Implementation (PLDI'08), 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. S. D. Stoller. Testing concurrent Java programs using randomized scheduling. In Workshop on Runtime Verification (RV'02), volume 70 of ENTCS, 2002.Google ScholarGoogle ScholarCross RefCross Ref
  27. C. von Praun. Detecting Synchronization Defects in Multi-Threaded Object-Oriented Programs. PhD thesis, Swiss Federal Institute of Technology, Zurich, 2004.Google ScholarGoogle Scholar
  28. C. von Praun and T. R. Gross. Object race detection. In 16th ACM SIGPLAN conference on Object oriented programming, systems, languages, and applications (OOPSLA), pages 70--82. ACM, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. A. Williams, W. Thies, and M. Ernst. Static deadlock detection for Java libraries. In ECOOP 2005 -- 19th European Conference on Object--Oriented Programming (ECOOP'05), pages 602--629, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. B. Xin, W. N. Sumner, and X. Zhang. Efficient program execution indexing. In ACM SIGPLAN conference on Programming language design and implementation, pages 238--248, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. A randomized dynamic program analysis technique for detecting real deadlocks

          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 44, Issue 6
            PLDI '09
            June 2009
            478 pages
            ISSN:0362-1340
            EISSN:1558-1160
            DOI:10.1145/1543135
            Issue’s Table of Contents
            • cover image ACM Conferences
              PLDI '09: Proceedings of the 30th ACM SIGPLAN Conference on Programming Language Design and Implementation
              June 2009
              492 pages
              ISBN:9781605583921
              DOI:10.1145/1542476

            Copyright © 2009 ACM

            Publisher

            Association for Computing Machinery

            New York, NY, United States

            Publication History

            • Published: 15 June 2009

            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!