ArXiv TLDR

Verification Modulo Tested Library Contracts

🐦 Tweet
2604.15533

Abhishek Uppar, Omar Muhammad, Sumanth Prabhu, Deepak D'Souza, Madhusudan P + 1 more

cs.PLcs.LGcs.LOcs.SE

TLDR

This paper introduces a framework for verifying client programs using complex libraries by synthesizing modular and contextual contracts that are also testable.

Key contributions

  • Formulates client program verification using complex libraries as contract synthesis.
  • Introduces "contextual contracts" that simplify library method specifications for clients.
  • Proposes a counterexample-guided learning framework for inferring contracts and invariants.
  • Implements this in `vmtlc`, showing efficacy on benchmarks with large libraries.

Why it matters

Verifying client programs that use complex libraries is a significant challenge in software engineering. This paper offers a novel approach by synthesizing testable, context-aware contracts, simplifying the verification process. Its framework and tool can greatly enhance the reliability of software built upon extensive library ecosystems.

Original Abstract

We consider the problem of \emph{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 \emph{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 \vmtlc and show its efficacy on benchmarks where clients call large libraries.

📬 Weekly AI Paper Digest

Get the top 10 AI/ML arXiv papers from the week — summarized, scored, and delivered to your inbox every Monday.