A practical method is presented for automating in a uniform way the verification of Pascal programs that operate on the standard Pascal data structures Array, Record, and Pointer. New assertion language primitives are introduced for describing computational effects of operations on these data structures. Axioms defining the semantics of the new primitives are given. Proof rules for standard Pascal operations on data structures are then defined using the extended assertion language. An axiomatic rule for the Pascal storage allocation operation, NEW, is also given. These rules have been implemented in the Stanford Pascal program verifier. Examples illustrating the verification of programs which operate on list structures implemented with pointers and records are discussed. These include programs with side effects.
A program annotated with inductive assertions is said to be verification decidable if ail of the verification conditions generated from the program and assertions are formulas in a decidable theory. We define a theory, which we call Presburger array theory, containing two logical sorts: integer and array-of-integer.Addition, subtraction, and comparisons are permitted for integers. We allow array contents and assign functions, and, since the elements of the arrays are integers, array accesses may be nested. The first result is that the validity of unquantified formulas in Presburger array theory is decidable, yet quantified formulas in general are undecidable. We also show that, with certain restrictions, we can add a new predicate Perm(M,N) ~ meaning array M is a permutation of array N -to the assertion language and still have a solvable decision problem for verification conditions generated from unquantified assertions. The significance of this result is that almost all known sorting programs, when annotated with inductive assertions for proving that the output is a permutation of the input, are verification decidable.
scite is a Brooklyn-based organization that helps researchers better discover and understand research articles through Smart Citations–citations that display the context of the citation and describe whether the article provides supporting or contrasting evidence. scite is used by students and researchers from around the world and is funded in part by the National Science Foundation and the National Institute on Drug Abuse of the National Institutes of Health.