A Counterexample-guided Approach to Finding Numerical Invariants
ThanhVu Nguyen, Timos Antopoulos, Andrew Ruef, and Michael Hicks

TL;DR
NumInv is a tool that automatically discovers polynomial numerical invariants in programs using a counterexample-guided approach, aiding program analysis and verification, especially for complex arithmetic and complexity bounds.
Contribution
It introduces a novel CEGIR-based method that sacrifices soundness for practical invariant discovery, leveraging KLEE for dynamic verification and outperforming existing tools.
Findings
NumInv successfully finds invariants for complex arithmetic programs.
It captures precise complexity bounds in benchmark programs.
NumInv performs competitively with state-of-the-art tools.
Abstract
Numerical invariants, e.g., relationships among numerical variables in a program, represent a useful class of properties to analyze programs. General polynomial invariants represent more complex numerical relations, but they are often required in many scientific and engineering applications. We present NumInv, a tool that implements a counterexample-guided invariant generation (CEGIR) technique to automatically discover numerical invariants, which are polynomial equality and inequality relations among numerical variables. This CEGIR technique infers candidate invariants from program traces and then checks them against the program source code using the KLEE test-input generation tool. If the invariants are incorrect KLEE returns counterexample traces, which help the dynamic inference obtain better results. Existing CEGIR approaches often require sound invariants, however NumInv…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsFormal Methods in Verification · Software Testing and Debugging Techniques · Software Reliability and Analysis Research
