|
This article is cited in 6 scientific papers (total in 6 papers)
Loop invariants elimination for definite iterations over unchangeable data structures in C programs
I. V. Maryasov, V. A. Nepomniaschy A.P. Ershov Institute of Informatics Systems SB RAS,
Akademik Lavrentiev pr., 6, Novosibirsk, 630090, Russia
Abstract:
The C-program verification is an urgent problem of modern programming. To apply known methods of deductive verification it is necessary to provide loop invariants which might be a challenge in many cases. In this paper we consider the C-light language [18] which is a powerful subset of the ISO C language. To verify C-light programs the two-level approach [19, 20] and the mixed axiomatic semantics method [1, 3, 11] were suggested. At the first stage, we translate [17] the source C-light program into C-kernel one. The C-kernel language [19] is a subset of C-light. The theorem of translation correctness was proved in [10, 11]. The C-kernel has less statements with respect to the C-light, this allows to decrease the number of inference rules of axiomatic semantics during its development. At the second stage of this approach, the verification conditions are generated by applying the rules of mixed axiomatic semantics [10, 11] which could contain several rules for the same program statement. In such cases the inference rules are applied depending on the context. Let us note that application of the mixed axiomatic semantics allows to significantly simplify verification conditions in many cases. This article represents an extension of this approach which includes our verification method for definite iteration over unchangeable data structures without loop exit in C-light programs. The method contains a new inference rule for the deifinite iteration without invariants. This rule was implemented in verification conditions generator. At the proof stage the SMT-solver Z3 [12] is used. An example which illustrates the application of this technique is considered.
The article is published in the authors' wording.
Keywords:
C-light, loop invariants, mixed axiomatic semantics, definite iteration, unchangeable data structures, Z3, specification, verification, Hoare logic.
Received: 26.10.2015
Citation:
I. V. Maryasov, V. A. Nepomniaschy, “Loop invariants elimination for definite iterations over unchangeable data structures in C programs”, Model. Anal. Inform. Sist., 22:6 (2015), 773–782
Linking options:
https://www.mathnet.ru/eng/mais473 https://www.mathnet.ru/eng/mais/v22/i6/p773
|
|