Automatic Generation of Local Repairs for Boolean Programs

Automatic techniques for software verification focus on obtaining witnesses of program failure. Such counterexamples often fail to localize the precise cause of an error and usually do not suggest a repair strategy. We present an efficient algorithm to automatically generate a repair for an incorrect sequential Boolean program where program correctness is specified using a pre-condition and a post-condition. Our approach draws on standard techniques from predicate calculus to obtain annotations for the program statements. These annotations are then used to generate a synthesis query for each program statement, which if successful, yields a repair. Furthermore, we show that if a repair exists for a given program under specified conditions, our technique is always able to find it.

[1]  Edsger W. Dijkstra,et al.  Predicate Calculus and Program Semantics , 1989, Texts and Monographs in Computer Science.

[2]  Sanjit A. Seshia,et al.  Combinatorial sketching for finite programs , 2006, ASPLOS XII.

[3]  Mayur Naik,et al.  From symptom to cause: localizing errors in counterexample traces , 2003, POPL '03.

[4]  Georg Gottlob,et al.  Enhancing Model Checking in Verification by AI Techniques , 1999, Artif. Intell..

[5]  Kavita Ravi,et al.  Fate and free will in error traces , 2004, International Journal on Software Tools for Technology Transfer.

[6]  Valentin Goranko,et al.  Logic in Computer Science: Modelling and Reasoning About Systems , 2007, J. Log. Lang. Inf..

[7]  Sriram K. Rajamani,et al.  Boolean Programs: A Model and Process for Software Analysis , 2000 .

[8]  Anish Arora,et al.  Synthesis of fault-tolerant concurrent programs , 2004, TOPL.

[9]  Edsger W. Dijkstra,et al.  A Discipline of Programming , 1976 .

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

[11]  Louise A. Dennis,et al.  Program Slicing and Middle-Out Reasoning for Error Location and Repair , 2006 .

[12]  Thomas A. Henzinger,et al.  Software Verification with BLAST , 2003, SPIN.

[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]  Sriram K. Rajamani,et al.  Automatically validating temporal safety properties of interfaces , 2001, SPIN '01.

[16]  Ali Ebnenasir,et al.  Revising UNITY Programs: Possibilities and Limitations , 2005, OPODIS.

[17]  Kavita Ravi,et al.  Fate and free will in error traces , 2004, International Journal on Software Tools for Technology Transfer.

[18]  K. Mani Chandy,et al.  Parallel program design - a foundation , 1988 .

[19]  Louise A. Dennis,et al.  Proof-Directed Debugging and Repair , 2006 .

[20]  Yan Zhang,et al.  CTL Model Update for System Modifications , 2011, J. Artif. Intell. Res..

[21]  Alex Groce,et al.  SPECIAL S ECTION O N T OOLS A ND A LGORITHMS F OR THE C ONSTRUCTION A ND A NALYSIS O F S YSTEMS , 2005 .

[22]  Roderick Bloem,et al.  Fault Localization and Correction with QBF , 2007, SAT.