Counterexample Driven Quantifier Instantiations with Applications to Distributed Protocols
Orr Tamir, Marcelo Taube, Kenneth L. McMillan, Sharon Shoham, Jon Howell, Guy Gueta, Mooly Sagiv
Abstract
Formally verifying infinite-state systems can be a daunting task, especially when it comes to reasoning about quantifiers. In particular, quantifier alternations in conjunction with function symbols can create function cycles that result in infinitely many ground terms, making it difficult for solvers to instantiate quantifiers and causing them to diverge. This can leave users with no useful information on how to proceed. To address this issue, we propose an interactive verification methodology that uses a relational abstraction technique to mitigate solver divergence in the presence of quantifiers. This technique abstracts functions in the verification conditions (VCs) as one-to-one relations, which avoids the creation of function cycles and the resulting proliferation of ground terms. Relational abstraction is sound and guarantees correctness if the solver cannot find counter-models. However, it may also lead to false counterexamples, which can be addressed by refining the abstraction and requiring the existence of corresponding elements. In the domain of distributed protocols, we can refine the abstraction by diagnosing counterexamples and manually instantiating elements in the range of the original function. If the verification conditions are correct, there always exist finitely many refinement steps that eliminate all spurious counter-models, making the approach complete. We applied this approach in Ivy to verify the safety properties of consensus protocols and found that: (1) most verification goals can be automatically verified using relational abstraction, while SMT solvers often diverge when given the original VC, (2) only a few manual instantiations were needed, and the counterexamples provided valuable guidance for the user compared to timeouts produced by the traditional approach, and (3) the technique can be used to derive efficient low-level implementations of tricky algorithms.
Ask about this paper
Ask your agent about it.
Lune has read the top-tier papers around this one, so every answer names the papers it rests on.
Your agent calls
Lunesearch_papers
Free to start. No credit card required.
Terminal
Install the CLIlune papers get f4898fca-8c24-4f54-8a48-6ff5770d069aCited by top-tier papers2
- Decidability Results for Fragments of First-Order Logic via a Symbolic Model PropertyNeta Elad, Sharon ShohamLICS 2026
- Effectively Propositional Higher-Order Functional ProgrammingNicholas V. Lewchenko, Kunha Kim, Bor-Yuh Evan Chang, Gowtham KakiOOPSLA 2026
Related papers
- DuoAI: Fast, Automated Inference of Inductive Invariants for Verifying Distributed ProtocolsJianan Yao, Runzhou Tao, Ronghui Gu, Jason NiehOSDI 2022 · 50 citations
- Infinite-State Liveness Checking with rliveAlessandro Cimatti, Alberto Griggio, Christopher Johannsen, Kristin Yvonne Rozier et al.CAV 2025 · 2 citations
- Mostly Automated Verification of Liveness Properties for Distributed Protocols with Ranking FunctionsJianan Yao, Runzhou Tao, Ronghui Gu, Jason NiehPOPL 2024 · 12 citations
- An Infinite Needle in a Finite Haystack: Finding Infinite Counter-Models in Deductive VerificationNeta Elad, Oded Padon, Sharon ShohamPOPL 2024 · 4 citations
- Learning to Synthesize Relational InvariantsJingbo Wang, Chao WangASE 2022 · 9 citations
