Verifying while loops with invariant relations

Traditionally, invariant assertions are used to verify the partial correctness of while loops with respect to pre/post specifications. In this paper we discuss a related but distinct concept, namely invariant relations, and show how invariant relations are a more potent tool in the analysis of while loops: whereas invariant assertions can only be used to prove partial correctness, invariant relations can be used to prove total correctness; also, whereas invariant assertions can only be used to prove correctness, invariant relations can be used to prove correctness and can also be used to prove incorrectness; finally, where traditional studies of loop termination equate termination with iterating a finite number of times, we broaden the definition of termination to also capture the condition that each individual iteration proceeds without raising an exception.

[1]  Daniel Kroening,et al.  Loopfrog - loop summarization for static analysis , 2010, WING@ETAPS/IJCAR.

[2]  David Gries,et al.  The Science of Programming , 1981, Text and Monographs in Computer Science.

[3]  Ali Mili,et al.  On the lattice of specifications: Applications to a specification methodology , 2005, Formal Aspects of Computing.

[4]  Lamia Labed Jilani,et al.  Invariant relations, invariant functions, and loop functions , 2012, Innovations in Systems and Software Engineering.

[5]  Sumit Gulwani,et al.  Lifting abstract interpreters to quantified logical domains , 2008, POPL '08.

[6]  David S. Janzen,et al.  Test-driven development concepts, taxonomy, and future direction , 2005, Computer.

[7]  Gudmund Grov,et al.  Synthesising Functional Invariants in Separation Logic , 2010, WING@ETAPS/IJCAR.

[8]  Bertrand Meyer,et al.  Inferring Loop Invariants Using Postconditions , 2010, Fields of Logic and Computation.

[9]  Shuvendu K. Lahiri,et al.  Differential assertion checking , 2013, ESEC/FSE 2013.

[10]  Muhammad Ali Shah,et al.  Proving Programs Incorrect Using a Sequent Calculus for Java Dynamic Logic , 2007, TAP.

[11]  Lamia Labed Jilani,et al.  Invariant assertions, invariant relations, and invariant functions , 2013, Sci. Comput. Program..

[12]  Andreas Podelski,et al.  Heap Assumptions on Demand , 2008, CAV.

[13]  Deepak Kapur,et al.  Termination Analysis of Imperative Programs Using Bitvector Arithmetic , 2012, VSTTE.

[14]  Koushik Sen,et al.  Looper: Lightweight Detection of Infinite Loops at Runtime , 2009, 2009 IEEE/ACM International Conference on Automated Software Engineering.

[15]  Lamia Labed Jilani,et al.  Invariant functions and invariant relations: An alternative to invariant assertions , 2013, J. Symb. Comput..

[16]  Florian Zuleger,et al.  LOOPUS - A Tool for Computing Loop Bounds for C Programs , 2010, WING@ETAPS/IJCAR.

[17]  Rui Abreu,et al.  Prioritizing tests for fault localization through ambiguity group reduction , 2011, 2011 26th IEEE/ACM International Conference on Automated Software Engineering (ASE 2011).

[18]  Lamia Labed Jilani,et al.  Invariant relations: an automated tool to analyze loops , 2011 .

[19]  Sumit Gulwani,et al.  Test-driven synthesis , 2014, PLDI.

[20]  Philipp Rümmer,et al.  Non-termination Checking for Imperative Programs , 2008, TAP.

[21]  Sumit Gulwani,et al.  Proving Conditional Termination , 2008, CAV.

[22]  Enric Rodríguez-Carbonell,et al.  Program Verification Using Automatic Generation of Invariants , 2004, ICTAC.

[23]  Andreas Podelski,et al.  Transition Invariants and Transition Predicate Abstraction for Program Termination , 2011, TACAS.

[24]  Stephen McCamant,et al.  The Daikon system for dynamic detection of likely invariants , 2007, Sci. Comput. Program..

[25]  William R. Harris,et al.  Alternation for Termination , 2010, SAS.

[26]  R. Adams Proceedings , 1947 .

[27]  Lamia Labed Jilani,et al.  A versatile concept for the analysis of loops , 2012, J. Log. Algebraic Methods Program..

[28]  W. Eric Wong,et al.  Combining mutation and fault localization for automated program debugging , 2014, J. Syst. Softw..

[29]  Thomas A. Henzinger,et al.  Proving non-termination , 2008, POPL '08.

[30]  Laura Kovács,et al.  An algorithm for automated generation of invariants for loops with conditionals , 2005, Seventh International Symposium on Symbolic and Numeric Algorithms for Scientific Computing (SYNASC'05).

[31]  Kwangkeun Yi,et al.  Termination Analysis with Algorithmic Learning , 2012, CAV.

[32]  Henny B. Sipma,et al.  Termination Analysis of Integer Linear Loops , 2005, CONCUR.

[33]  Farokh B. Bastani,et al.  Automated Discovery of Loop Invariants for High-Assurance Programs Synthesized Using AI Planning Techniques , 2008, 2008 11th IEEE High Assurance Systems Engineering Symposium.

[34]  Claire Le Goues,et al.  A systematic study of automated program repair: Fixing 55 out of 105 bugs for $8 each , 2012, 2012 34th International Conference on Software Engineering (ICSE).

[35]  Ali Mili,et al.  Mathematics for reasoning about loop functions , 2009, Sci. Comput. Program..

[36]  Henny B. Sipma,et al.  Non-linear loop invariant generation using Gröbner bases , 2004, POPL.

[37]  Tomás Vojnar,et al.  Tool Demonstration of the FLATA Counter Automata Toolset , 2010, WING@ETAPS/IJCAR.

[38]  Tudor Jebelean,et al.  Automated Generation of Loop Invariants by Recurrence Solving in Theorema , 2004 .

[39]  Andrei Voronkov,et al.  Finding Loop Invariants for Programs over Arrays Using a Theorem Prover , 2009, FASE.

[40]  A. Rybalchenko,et al.  Transition invariants , 2004, LICS 2004.

[41]  Eric C. R. Hehner,et al.  A Practical Theory of Programming , 1993, Texts and Monographs in Computer Science.

[42]  Jürgen Giesl,et al.  Approximating the Domains of Functional and Imperative Programs , 1999, Sci. Comput. Program..

[43]  Jules Desharnais,et al.  Relational Mathematics for Relative Correctness , 2015, RAMICS.

[44]  Ashish Tiwari,et al.  Termination of Linear Programs , 2004, CAV.

[45]  Andreas Podelski,et al.  Termination proofs for systems code , 2006, PLDI '06.

[46]  Andrei Voronkov,et al.  Interpolation and Symbol Elimination in Vampire , 2010, IJCAR.

[47]  Henny B. Sipma,et al.  Practical Methods for Proving Program Termination , 2002, CAV.

[48]  Sumit Gulwani,et al.  Ranking Abstractions , 2008, ESOP.

[49]  Carl E. Landwehr,et al.  Basic concepts and taxonomy of dependable and secure computing , 2004, IEEE Transactions on Dependable and Secure Computing.

[50]  Ali Mili,et al.  Correctness and Relative Correctness , 2015, 2015 IEEE/ACM 37th IEEE International Conference on Software Engineering.

[51]  Ewen Denney,et al.  A generic annotation inference algorithm for the safety certification of automatically generated code , 2006, GPCE '06.

[52]  C. A. R. HOARE,et al.  An axiomatic basis for computer programming , 1969, CACM.

[53]  Daniel Kroening,et al.  Loop Summarization and Termination Analysis , 2011, TACAS.

[54]  Fan Long,et al.  An analysis of patch plausibility and correctness for generate-and-validate patch generation systems , 2015, ISSTA.

[55]  Claire Le Goues,et al.  Current challenges in automatic software repair , 2013, Software Quality Journal.

[56]  Andreas Podelski,et al.  A Complete Method for the Synthesis of Linear Ranking Functions , 2004, VMCAI.