Abstraction-guided synthesis of synchronization

We present a novel framework for automatic inference of efficient synchronization in concurrent programs, a task known to be difficult and error-prone when done manually. Our framework is based on abstract interpretation and can infer synchronization for infinite state programs. Given a program, a specification, and an abstraction, we infer synchronization that avoids all (abstract) interleavings that may violate the specification, but permits as many valid interleavings as possible. Combined with abstraction refinement, our framework can be viewed as a new approach for verification where both the program and the abstraction can be modified on-the-fly during the verification process. The ability to modify the program, and not only the abstraction, allows us to remove program interleavings not only when they are known to be invalid, but also when they cannot be verified using the given abstraction. We implemented a prototype of our approach using numerical abstractions and applied it to verify several interesting programs.

[1]  Armando Solar-Lezama,et al.  Sketching concurrent data structures , 2008, PLDI '08.

[2]  Pierre Wolper,et al.  Synthesis of Communicating Processes from Temporal Logic Specifications , 1981, TOPL.

[3]  Amir Pnueli,et al.  On the synthesis of a reactive module , 1989, POPL '89.

[4]  Edmund M. Clarke,et al.  Counterexample-Guided Abstraction Refinement , 2000, CAV.

[5]  Thomas A. Henzinger,et al.  Lazy abstraction , 2002, POPL '02.

[6]  Antoine Miné,et al.  The octagon abstract domain , 2001, High. Order Symb. Comput..

[7]  Roderick Bloem,et al.  Finding and Fixing Faults , 2005, CHARME.

[8]  Eran Yahav,et al.  Deriving linearizable fine-grained concurrent objects , 2008, PLDI '08.

[9]  Patrick Cousot,et al.  A static analyzer for large safety-critical software , 2003, PLDI '03.

[10]  Antoine Mid The Octagon Abstract Domain , 2001 .

[11]  Roderick Bloem,et al.  Program Repair as a Game , 2005, CAV.

[12]  Krishnendu Chatterjee,et al.  Better Quality in Synthesis through Quantitative Objectives , 2009, CAV.

[13]  Armando Solar-Lezama,et al.  Programming by sketching for bit-streaming programs , 2005, PLDI '05.

[14]  Roderick Bloem,et al.  Repair of Boolean Programs with an Application to C , 2006, CAV.

[15]  Eran Yahav,et al.  CGCExplorer: a semi-automated search procedure for provably correct concurrent collectors , 2007, PLDI '07.

[16]  Eran Yahav,et al.  Inferring Synchronization under Limited Observability , 2009, TACAS.

[17]  David Gay,et al.  Autolocker: synchronization inference for atomic sections , 2006, POPL '06.

[18]  Sumit Gulwani,et al.  Inferring locks for atomic sections , 2008, PLDI '08.

[19]  Sriram K. Rajamani,et al.  Automatically validating temporal safety properties of interfaces , 2001, SPIN '01.

[20]  Eran Yahav,et al.  Partial-coherence abstractions for relaxed memory models , 2011, PLDI '11.

[21]  Edmund M. Clarke,et al.  Design and Synthesis of Synchronization Skeletons Using Branching Time Temporal Logic , 2008, 25 Years of Model Checking.

[22]  Pierre Wolper,et al.  An Automata-Theoretic Approach to Automatic Program Verification (Preliminary Report) , 1986, LICS.

[23]  Sriram K. Rajamani,et al.  Controlling Non-determinism for Semantic Guarantees , 2008 .

[24]  Rupak Majumdar,et al.  Lock allocation , 2007, POPL '07.

[25]  Paul C. Attie,et al.  Synthesis of concurrent systems for an atomic read/atomic write model of computation , 1996, PODC '96.

[26]  Edmund M. Clarke,et al.  Model Checking , 1999, Handbook of Automated Reasoning.

[27]  Nir Shavit,et al.  Software transactional memory , 1995, PODC '95.

[28]  Eran Yahav,et al.  Automatic inference of memory fences , 2010, Formal Methods in Computer Aided Design.

[29]  Sanjit A. Seshia,et al.  Sketching stencils , 2007, PLDI '07.

[30]  Patrick Cousot,et al.  Abstract interpretation: a unified lattice model for static analysis of programs by construction or approximation of fixpoints , 1977, POPL.

[31]  Xavier Rival,et al.  The trace partitioning abstract domain , 2007, TOPL.