Verification Modulo Tested Library Contracts
Abhishek Uppar, Omar Muhammad, Sumanth Prabhu S, Deepak D'Souza, P. Madhusudan, Adithya Murali
Abstract
We consider the problem of verification modulo tested library contracts as a step towards automating the verification of client programs that use complex libraries. We formulate this problem as the synthesis of modular contracts for the library methods used by the client that are adequate to prove the client correct, and that also pass the scrutiny of a testing engine that tests the library against these contracts. We also consider a new form of method contracts called contextual contracts that arise in this setting that hold in the context of the client program, and can often be simpler and easier to infer than classical modular contracts. We provide a counterexample-guided learning framework to solve this problem, in which the synthesizer interacts with a constraint solver as well as the testing engine in order to infer adequate modular/contextual method contracts and inductive invariants for the client. The main synthesis engines we use are generalizing CHC solvers that are realized using ICE learning algorithms. We realize this framework in a tool called Dualis and show its efficacy on benchmarks where clients call large libraries.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 2727c6ea-aacc-474c-9074-009a2922b8aeBuilds on10
- Can Large Language Models Reason about Program Invariants?Kexin Pei, David Bieber, Kensen Shi, Charles Sutton et al.ICML 2023 · 128 citations
- Enchanting Program Specification Synthesis by Large Language Models Using Static Analysis and Program VerificationCheng Wen, Jialun Cao, Jie Su, Zhiwu Xu et al.CAV 2024 · 60 citations
- Data-driven inference of representation invariantsAnders Miltner, Saswat Padhi, Todd D. Millstein, David WalkerPLDI 2020 · 33 citations
- Specification synthesis with constrained Horn clausesSumanth Prabhu S, Grigory Fedyukovich, Kumar Madhukar, Deepak D'SouzaPLDI 2021 · 24 citations
- Almost correct invariants: synthesizing inductive invariants by fuzzing proofsSumit Lahiri, Subhajit RoyISSTA 2022 · 18 citations
Related papers
- Counterexample-Guided Inference of Modular SpecificationsWilliam T. Hallahan, Ranjit Jhala, Ruzica PiskacOOPSLA 2025 · 1 citation
- Data-driven abductive inference of library specificationsZhe Zhou, Robert Dickerson, Benjamin Delaware, Suresh JagannathanOOPSLA 2021 · 15 citations
- Synthesizing Formal Semantics from Executable InterpretersJiangyi Liu, Charlie Murphy, Anvay Grover, Keith J. C. Johnson et al.OOPSLA 2024
- Synthesizing contracts correct modulo a test generatorAngello Astorga, Shambwaditya Saha, Ahmad Dinkins, Felicia Wang et al.OOPSLA 2021 · 13 citations
- Synthesizing Implication Lemmas for Interactive Theorem ProvingAna Brendel, Aishwarya Sivaraman, Todd D. MillsteinOOPSLA 2025
