skip to main content
10.1145/2483760.2483771acmconferencesArticle/Chapter ViewAbstractPublication PagesisstaConference Proceedingsconference-collections
research-article

SimRacer: an automated framework to support testing for process-level races

Published:15 July 2013Publication History

ABSTRACT

Faults introduced by races are difficult to detect because they usually occur only under specific execution interleavings. Numerous program analysis and testing techniques have been proposed to detect races between threads. Little work, however, has addressed the problem of detecting and testing for process-level races, in which two processes access a shared resource without proper synchronization. In this paper, we present SIMRACER, a novel testing-based framework that allows engineers to effectively test for process-level races. SIMRACER first computes potential races based on runtime traces obtained by running existing tests on target processes, and then it controls process scheduling relative to the potential races so that real races can be created. We implemented SIMRACER on a commercial virtual platform that is widely used to support hardware/software co-design. We then evaluated its effectiveness on sixteen real-world applications containing known process-level races. Our results show that SIMRACER is effective at detecting process-level races, and more effective than traditional stress testing techniques at detecting faults caused by those races.

References

  1. Android Race, 2010. https://android.googlesource.com/platform/frameworks- /base/+/e6b1bbd8acca3f6e174c24cf4eb23a66db2d08a2.Google ScholarGoogle Scholar
  2. Apache Deadlock, 2003. http://marc.info/?l=apache-httpdbugs&m=105967988713871.Google ScholarGoogle Scholar
  3. M. D. Bond, K. E. Coons, and K. S. McKinley. PACER: Proportional detection of data races. In ACM SIGPLAN Conf. Prog. Land. Des. Impl., 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. 2004. https://bugs.launchpad.net/debian/+source/bash /+bug/10809/comments/0.Google ScholarGoogle Scholar
  5. 2008. http://ftp.gnu.org/gnu/bash/bash-3.2-patches/ bash32-051.Google ScholarGoogle Scholar
  6. 2011. http://ftp.gnu.org/gnu/bash/bash-4.2-patches/ bash42-023.Google ScholarGoogle Scholar
  7. 2011. http://www.mail-archive.com/[email protected]/msg918886.html.Google ScholarGoogle Scholar
  8. 2000. http://bugs.debian.org/cgi-bin/bugreport.cgi ?bug=67782.Google ScholarGoogle Scholar
  9. 2011. http://bugs.debian.org/cgi-bin/bugreport.cgi ?bug=461585.Google ScholarGoogle Scholar
  10. 2010. https://rhn.redhat.com/errata/RHBA-2010-0174.html.Google ScholarGoogle Scholar
  11. 2008. https://bugzilla.redhat.com/show_bug.cgi?id=438076.Google ScholarGoogle Scholar
  12. 2004. http://lists.gnu.org/archive/html/bug-coreutils/2004- 04/msg00126.html.Google ScholarGoogle Scholar
  13. 2001. https://bugzilla.redhat.com/show_bug.cgi?id=54127.Google ScholarGoogle Scholar
  14. 2006. http://bugs.debian.org/cgi-bin/bugreport.cgi ?bug=357140.Google ScholarGoogle Scholar
  15. 2005. http://www.securityfocus.com/archive/1/395489.Google ScholarGoogle Scholar
  16. 2007. https://bugs.launchpad.net/ubuntu/+source /coreutils/5.97-5.6ubuntu1.Google ScholarGoogle Scholar
  17. 2009. https://bugs.gentoo.org/show_bug.cgi?id=231775.Google ScholarGoogle Scholar
  18. A. Causevic, D. Sundmark, and S. Punnekkat. An industrial survey on contemporary aspects of softw. test. In Int’l. Conf. Softw. Test., Verif. Valid., 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. J. Engblom, D. Aarno, and B. Werner. Full-System Simulation from Embedded to High-Performance Systems. 2010.Google ScholarGoogle Scholar
  20. D. Engler and K. Ashcraft. RacerX: Effective, static detection of race conditions and deadlocks. In ACM Symp. Op. Sys. Princ., 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. K.-H. K. Guy Martin Tchamgoue, Ok-Kyoon Ha and Y.-K. Jun. Lightweight labeling scheme for on-the-fly race detection of signal handlers. Ubiq. Comp. Multim. Apps., 2011.Google ScholarGoogle Scholar
  22. B. Kasikci, C. Zamfir, and G. Candea. Data races vs. data race bugs: telling the difference with portend. In Int’l. Conf. Arch. Sup. Prog. Langs. Op. Sys., 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. O. Laadan, N. Viennot, C.-C. Tsai, C. Blinn, J. Yang, and J. Nieh. Pervasive detection of process races in deployed systems. In ACM Symp. Op. Sys. Princ., 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. D. Li, W. Srisa-an, and M. B. Dwyer. Sos: Saving time in dynamic race detection with stationary analysis. In Int’l. Conf. O.-O. Prog. Sys. Langs. Apps., 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. S. Lu, S. Park, E. Seo, and Y. Zhou. Learning from mistakes: A comprehensive study on real world concurrency bug characteristics. In Int’l. Conf. Arch. Sup. Prog. Langs. Op. Sys., 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. M. Musuvathi, S. Qadeer, T. Ball, G. Basler, P. A. Nainar, and I. Neamtiu. Finding and reproducing heisenbugs in concurrent programs. In Conf. Op. Sys. Des. Impl, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. S. Narayanasamy, Z. Wang, J. Tigani, A. Edwards, and B. Calder. Automatically classifying benign and harmful data races using replay analysis. In ACM SIGPLAN Conf. Prog. Lang. Des. Impl, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  28. Facebook IPO Glitch, 2012. http://www.cio.com.au/article/425234/ nasdaq_facebook_glitch_came_from_race_conditions/.Google ScholarGoogle Scholar
  29. T. J. Ostrand and M. J. Balcer. The category-partition method for specifying and generating fuctional tests. Comm. ACM, June 1988. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. S. Park, S. Lu, and Y. Zhou. CTrigger: Exposing atomicity violation bugs from their hiding places. In Int’l. Conf. Arch. Sup. Prog. Langs. Op. Sys., 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. S. Park, R. W. Vuduc, and M. J. Harrold. Falcon: Fault localization in concurrent programs. In Int’l. Conf. Softw. Eng., 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. M. Payer and T. R. Gross. Protecting applications against tocttou races by user-space caching of file metadata. In Int’l. Conf. Virt. Exe. Envs., 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. R. Raman, J. Zhao, V. Sarkar, M. Vechev, and E. Yahav. Scalable and precise dynamic datarace detection for structured parallelism. In ACM SIGPLAN Conf. Prog. Lang. Des. Impl, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. K. Sen. Race directed random testing of concurrent programs. In ACM SIGPLAN Conf. Prog. Lang. Des. Impl, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  35. K. Serebryany and T. Iskhodzhanov. Threadsanitizer: data race detection in practice. In W. Binary Instr. Apps., 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  36. T. Sheng, N. Vachharajani, S. Eranian, R. Hundt, W. Chen, and W. Zheng. RACEZ: A lightweight and non-invasive race detection tool for production applications. In Int’l. Conf. Softw. Eng., 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  37. Test Strategies for Smartphones and Mobile Devices, 2010. http://www.macadamian.com/images/uploads/whitepapers- /MobileTestStrategies_Aug2010.pdf.Google ScholarGoogle Scholar
  38. F. Sorrentino, A. Farzan, and P. Madhusudan. Penelope: weaving threads to expose atomicity violations. In Int’l. Symp. Found. Softw. Eng., 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  39. M. Staats, M. W. Whalen, and M. P. Heimdahl. Programs, tests, and oracles: The foundations of testing revisited. In Int’l. Conf. Softw. Eng., 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  40. Stress Testing, 2006. http://msdn.microsoft.com/en-us /magazine/cc163613.aspx.Google ScholarGoogle Scholar
  41. T. Tahara, K. Gondow, and S. Ohsuga. DRACULA: Detector of data races in signals handlers. In Asia-Pacific Softw. Eng. Conf., 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  42. D. Tsafrir, T. Hertz, D. Wagner, and D. Da Silva. Portably solving file TOCTTOU races with hardness amplification. In USENIX Conf. File Stor. Tech., 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  43. UART Race, 2011. http://lkml.org/lkml/2011/7/25/369.Google ScholarGoogle Scholar
  44. Web Site Test Tools and Site Management Tools, 2012. http://www.softwareqatest.com/qatweb1.html.Google ScholarGoogle Scholar
  45. J. Yu, S. Narayanasamy, C. Pereira, and G. Pokam. Maple: a coverage-driven testing tool for multithreaded programs. In ACM Int’l. Conf. O.-O. Prog. Sys. Langs. Apps., 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  46. T. Yu, W. Srisa-an, and G. Rothermel. Simtester: a controllable and observable testing framework for embedded systems. In Int’l. Conf. Virt. Exe. Envs., 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  47. T. Yu, A. Sung, W. Srisa-an, and G. Rothermel. Using property-based oracles when testing embedded system applications. In Int’l. Conf. Softw. Test., Verif. Val., 2011. 11 Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. SimRacer: an automated framework to support testing for process-level races

    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
    • Published in

      cover image ACM Conferences
      ISSTA 2013: Proceedings of the 2013 International Symposium on Software Testing and Analysis
      July 2013
      381 pages
      ISBN:9781450321594
      DOI:10.1145/2483760

      Copyright © 2013 ACM

      Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

      Publisher

      Association for Computing Machinery

      New York, NY, United States

      Publication History

      • Published: 15 July 2013

      Permissions

      Request permissions about this article.

      Request Permissions

      Check for updates

      Qualifiers

      • research-article

      Acceptance Rates

      Overall Acceptance Rate58of213submissions,27%

      Upcoming Conference

      ISSTA '24

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader