Concurrency testing using schedule bounding: an empirical study

We present the first independent empirical study on schedule bounding techniques for systematic concurrency testing (SCT). We have gathered 52 buggy concurrent software benchmarks, drawn from public code bases, which we call SCTBench. We applied a modified version of an existing concurrency testing tool to SCTBench to attempt to answer several research questions, including: How effective are the two main schedule bounding techniques, preemption bounding and delay bounding, at bug finding? What challenges are associated with applying SCT to existing code? How effective is schedule bounding compared to a naive random scheduler at finding bugs? Our findings confirm that delay bounding is superior to preemption bounding and that schedule bounding is more effective at finding bugs than unbounded depth-first search. The majority of bugs in SCTBench can be exposed using a small bound (1-3), supporting previous claims, but there is at least one benchmark that requires 5 preemptions. Surprisingly, we found that a naive random scheduler is at least as effective as schedule bounding for finding bugs. We have made SCTBench and our tools publicly available for reproducibility and use in future work.

[1]  Satish Narayanasamy,et al.  Automatically classifying benign and harmful data races using replay analysis , 2007, PLDI '07.

[2]  Sebastian Burckhardt,et al.  Multicore acceleration of priority-based schedulers for concurrency bug detection , 2012, PLDI.

[3]  Hans-Juergen Boehm,et al.  How to Miscompile Programs with "Benign" Data Races , 2011, HotPar.

[4]  Koushik Sen,et al.  Race directed random testing of concurrent programs , 2008, PLDI '08.

[5]  Harish Patil,et al.  Pin: building customized program analysis tools with dynamic instrumentation , 2005, PLDI '05.

[6]  Patrice Godefroid,et al.  Model checking for programming languages using VeriSoft , 1997, POPL '97.

[7]  Madan Musuvathi,et al.  Fair stateless model checking , 2008, PLDI '08.

[8]  Shaz Qadeer,et al.  Partial-Order Reduction for Context-Bounded State Exploration , 2007 .

[9]  Thomas W. Reps,et al.  Reducing Concurrent Analysis Under a Context Bound to Sequential Analysis , 2008, CAV.

[10]  Dawson R. Engler,et al.  A few billion lines of code later , 2010, Commun. ACM.

[11]  James R. Larus,et al.  Software and the Concurrency Revolution , 2005, ACM Queue.

[12]  Satish Narayanasamy,et al.  A case for an interleaving constrained shared-memory multi-processor , 2009, ISCA '09.

[13]  Chao Wang,et al.  Coverage guided systematic concurrency testing , 2011, 2011 33rd International Conference on Software Engineering (ICSE).

[14]  Matteo Frigo,et al.  The implementation of the Cilk-5 multithreaded language , 1998, PLDI.

[15]  Thomas Ball,et al.  Finding and Reproducing Heisenbugs in Concurrent Programs , 2008, OSDI.

[16]  Kathryn S. McKinley,et al.  Bounded partial-order reduction , 2013, OOPSLA.

[17]  Stephen N. Freund,et al.  FastTrack: efficient and precise dynamic race detection , 2009, PLDI '09.

[18]  Gerard J. Holzmann,et al.  On Limits and Possibilities of Automated Protocol Analysis , 1987, PSTV.

[19]  Koushik Sen,et al.  RADBench: A Concurrency Bug Benchmark Suite , 2011, HotPar.

[20]  G. Gopalakrishnan,et al.  Inspect : A Runtime Model Checker for Multithreaded C Programs , 2008 .

[21]  Tomás Vojnar,et al.  A platform for search-based testing of concurrent software , 2010, PADTAD '10.

[22]  Jeff Huang,et al.  An Efficient Static Trace Simplification Technique for Debugging Concurrent Programs , 2011, SAS.

[23]  Bil Lewis,et al.  Multithreaded Programming With PThreads , 1997 .

[24]  Koushik Sen,et al.  A trace simplification technique for effective debugging of concurrent programs , 2010, FSE '10.

[25]  Patrice Godefroid,et al.  Dynamic partial-order reduction for model checking software , 2005, POPL '05.

[26]  Patrice Godefroid,et al.  Partial-Order Methods for the Verification of Concurrent Systems , 1996, Lecture Notes in Computer Science.

[27]  Gerard J. Holzmann,et al.  Model checking with bounded context switching , 2010, Formal Aspects of Computing.

[28]  Pravesh Kothari,et al.  A randomized scheduler with probabilistic guarantees of finding bugs , 2010, ASPLOS XV.

[29]  Lucas C. Cordeiro,et al.  Verifying multi-threaded software using smt-based context-bounded model checking , 2011, 2011 33rd International Conference on Software Engineering (ICSE).

[30]  George Candea,et al.  Data races vs. data race bugs: telling the difference with portend , 2012, ASPLOS XVII.

[31]  Christian Bienia,et al.  Benchmarking modern multiprocessors , 2011 .

[32]  Yuanyuan Zhou,et al.  CTrigger: exposing atomicity violation bugs from their hiding places , 2009, ASPLOS.

[33]  Anoop Gupta,et al.  The SPLASH-2 programs: characterization and methodological considerations , 1995, ISCA.

[34]  Madan Musuvathi,et al.  Iterative context bounding for systematic testing of multithreaded programs , 2007, PLDI '07.

[35]  Satish Narayanasamy,et al.  Maple: a coverage-driven testing tool for multithreaded programs , 2012, OOPSLA '12.

[36]  Zvonimir Rakamaric,et al.  Delay-bounded scheduling , 2011, POPL '11.