Separation logic: a logic for shared mutable data structures

In joint work with Peter O'Hearn and others, based on early ideas of Burstall, we have developed an extension of Hoare logic that permits reasoning about low-level imperative programs that use shared mutable data structure. The simple imperative programming language is extended with commands (not expressions) for accessing and modifying shared structures, and for explicit allocation and deallocation of storage. Assertions are extended by introducing a "separating conjunction" that asserts that its subformulas hold for disjoint parts of the heap, and a closely related "separating implication". Coupled with the inductive definition of predicates on abstract data structures, this extension permits the concise and flexible description of structures with controlled sharing. In this paper, we survey the current development of this program logic, including extensions that permit unrestricted address arithmetic, dynamically allocated arrays, and recursive procedures. We also discuss promising future directions.

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

[2]  C. Hoare Proof of a program: FIND , 1971, CACM.

[3]  S. Owicki,et al.  Verifying properties of parallel programs: an axiomatic approach , 1976, CACM.

[4]  John C. Reynolds,et al.  The craft of programming , 1981, Prentice Hall International series in computer science.

[5]  Mads Tofte,et al.  Implementation of the typed call-by-value λ-calculus using a stack of regions , 1994, POPL '94.

[6]  Luís Monteiro,et al.  Verifiable and Executable Logic Specifications of Concurrent Objects in Lpi , 1998, ESOP.

[7]  David Walker,et al.  Stack-based typed assembly language , 1998, Journal of Functional Programming.

[8]  John C. Reynolds,et al.  Intuitionistic reasoning about shared mutable data structure , 1999 .

[9]  Peter W. O'Hearn,et al.  The Logic of Bunched Implications , 1999, Bulletin of Symbolic Logic.

[10]  David Walker,et al.  Alias Types for Recursive Data Structures , 2000, Types in Compilation.

[11]  Luca Cardelli,et al.  Anytime, anywhere: modal logics for mobile ambients , 2000, POPL '00.

[12]  Peter W. O'Hearn,et al.  Reasoning about Shared Mutable Data Structure , 2001 .

[13]  Hongseok Yang,et al.  Local reasoning for stateful programs , 2001 .

[14]  Peter W. O'Hearn,et al.  Local Reasoning about Programs that Alter Data Structures , 2001, CSL.

[15]  Didier Galmiche,et al.  Proof-Search and Countermodel Generation in Propositional BI Logic , 2001, TACS.

[16]  Jerzy Tiuryn,et al.  Dynamic logic , 2001, SIGA.

[17]  Peter W. O'Hearn,et al.  Computability and Complexity Results for a Spatial Assertion Language for Data Structures , 2001, APLAS.

[18]  Peter W. O'Hearn,et al.  On Garbage and Program Logic , 2001, FoSSaCS.

[19]  Peter W. O'Hearn,et al.  BI as an assertion language for mutable data structures , 2001, POPL '01.

[20]  Luca Cardelli,et al.  A Query Language Based on the Ambient Logic , 2001, SEBD.

[21]  Hongseok Yang,et al.  An Example of Local Reasoning in BI Pointer Logic: the Schorr−Waite Graph Marking Algorithm , 2001 .

[22]  C. A. R. Hoare,et al.  An Axiomatic Basis for Computer Programming (Reprint) , 2002, Software Pioneers.

[23]  Luca Cardelli,et al.  A Spatial Logic for Querying Graphs , 2002, ICALP.

[24]  David J. Pym,et al.  The semantics and proof theory of the logic of bunched implications , 2002, Applied logic series.

[25]  David Walker,et al.  Stack-based typed assembly language , 2002, J. Funct. Program..

[26]  Paolo Manghi,et al.  The Query Language TQL , 2002, WebDB.

[27]  Charles Antony Richard Hoare Towards a theory of parallel programming , 2002 .

[28]  Peter W. O'Hearn,et al.  A Semantic Basis for Local Reasoning , 2002, FoSSaCS.

[29]  Cristiano Calcagno,et al.  Semantic and Logical Properties of Stateful Programming , 2002 .

[30]  David J. Pym,et al.  Resource Tableaux , 2002, CSL.

[31]  Peter W. O'Hearn Notes on Separation Logic for Shared-variable Concurrency , 2002 .

[32]  Peter W. O'Hearn,et al.  Program logic and equivalence in the presence of garbage collection , 2003, Theor. Comput. Sci..