,
K. Rustan M. Leino
Creative Commons Attribution 4.0 International license
Intermediate Verification Languages (IVLs) play the same role in verification as Intermediate Representations in compilation, a layer that separates a verifier’s language-specific front-end from its logic automation back-end. Successful IVL tools such as Boogie, Why3, and Viper generate Verification Conditions (VCs) that are sent to an SMT solver. The verifier output can be trusted only if these VCs are sound with respect to the formal semantics of the IVL. Formalizing the semantics of IVLs and verifying the soundness of corresponding VC Generators with respect to this semantics is challenging if one wants to model realistic features of IVLs such as mutually recursive definitions, lexical variable and control-flow labeled scopes, interpreted and uninterpreted functions, and unbounded loops. B3 is a new IVL. This paper presents a formalization of B3’s semantics, a VC Generator for the language, and a soundness proof that these two correspond. A key practical contribution of this work is that all three components are authored in the Dafny programming language and verifier. This makes it easy for a tool maintainer to maneuver between the semantic definitions, the proofs, and the VCG’s executable code. The key theoretical contribution of the work is a methodology to split the IVL’s semantic encodings into two layers of abstraction to cover realistic aspects of the semantics, while keeping the proofs amenable to automation. Optimized for Dafny-style automation, the first layer is used to verify the correctness of the VC Generator procedure. Optimized for expressiveness, the second layer is used to capture the semantics in a natural way.
@InProceedings{gladshtein_et_al:LIPIcs.ITP.2026.11,
author = {Gladshtein, Vladimir and Leino, K. Rustan M.},
title = {{Formalization of a Realistic Verification-Condition Generator for an Intermediate Verification Language}},
booktitle = {17th International Conference on Interactive Theorem Proving (ITP 2026)},
pages = {11:1--11:19},
series = {Leibniz International Proceedings in Informatics (LIPIcs)},
ISBN = {978-3-95977-436-9},
ISSN = {1868-8969},
year = {2026},
volume = {382},
editor = {Komendantskaya, Ekaterina and Nipkow, Tobias},
publisher = {Schloss Dagstuhl -- Leibniz-Zentrum f{\"u}r Informatik},
address = {Dagstuhl, Germany},
URL = {https://drops.dagstuhl.de/entities/document/10.4230/LIPIcs.ITP.2026.11},
URN = {urn:nbn:de:0030-drops-269855},
doi = {10.4230/LIPIcs.ITP.2026.11},
annote = {Keywords: Intermediate verification language, Soundness, Verification, B3, Dafny, SMT solvers}
}
archived version
archived version