|
Automatic verification of heap-manipulating programs
Yu. O. Kostyukova, K. A. Batoeva, D. A. Mordvinovba, M. P. Kostitsyna, A. V. Misonizhnika a Saint Petersburg State University
b JetBrains Research
Abstract:
Theoretical foundations of compositional reasoning about heaps in imperative programming languages are investigated. We introduce a novel concept of compositional symbolic memory and its relevant properties. We utilize these formal foundations to build up a compositional algorithm that generates generalized heaps, terms of symbolic heap calculus, which characterize arbitrary cyclic code segments. All states inferred by this calculus precisely correspond to reachable states of the original program. We establish the correspondence between inference in this calculus and execution of pure second-order functional programs. The contribution of this work is as follows: (1) a formal model of compositional symbolic memory is proposed; (2) the properties of its correctness are formulated; (3) the calculus of symbolic heaps has been introduced: the conclusions in this calculus give all attainable states of the program; (4) the concept of generalized heaps is introduced, an algorithm for automatic modular construction of generalized heaps according to an imperative program is proposed; (5) an approach is proposed to reduce the problem of finding an output in calculus of symbolic heaps to the problem of proving the safety of functional programs.
Keywords:
formal verification, automatic verification, symbolic execution, static analysis, dynamic memory, heap analysis, compositionality, pure functions.
Citation:
Yu. O. Kostyukov, K. A. Batoev, D. A. Mordvinov, M. P. Kostitsyn, A. V. Misonizhnik, “Automatic verification of heap-manipulating programs”, Proceedings of ISP RAS, 31:5 (2019), 37–62
Linking options:
https://www.mathnet.ru/eng/tisp452 https://www.mathnet.ru/eng/tisp/v31/i5/p37
|
Statistics & downloads: |
Abstract page: | 141 | Full-text PDF : | 53 | References: | 27 |
|