Solving constrained Horn clauses modulo algebraic data types and recursive functions

نویسندگان

چکیده

This work addresses the problem of verifying imperative programs that manipulate data structures, e.g., Rust programs. Data structures are usually modeled by Algebraic Types (ADTs) in verification conditions. Inductive invariants such often require recursively defined functions (RDFs) to represent abstractions structures. From logic perspective, this reduces solving Constrained Horn Clauses (CHCs) modulo both ADT and RDF. The underlying with RDFs is undecidable. Thus, even a candidate inductive invariant Similarly, IC3-based algorithms for CHCs lose their progress guarantee: they may not find counterexamples when program unsafe. We propose novel IC3-inspired algorithm Racer RDF (i.e., automatically synthesizing invariants, as opposed only them done deductive verification). ensures despite undecidability theory, guaranteed terminate counterexample unsafe It works general class over ADTs called catamorphisms. key idea catamorphisms CHCs, via relationification , RDFs, using . Encoding allows learning properties catamorphisms, well preserving unsatisfiabilty original use abstractions, whereas encoding unfolding recursive definition, relying on it solutions. Abstractions ensure theory remains decidable. implement our approach Z3 show practice.

برای دانلود رایگان متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Solving Constrained Horn Clauses using Interpolation

We present an interpolation-based method for symbolically solving systems of constrained Horn clauses. The method can be used to solve for unknown predicates in the verification conditions of programs. Thus, it has a variety of applications, including including model checking of recursive and threaded programs. The method is implemented in tool called Duality, which we evaluate using device dri...

متن کامل

Higher-Order Constrained Horn Clauses and Refinement Types

Motivated by applications in automated verification of higher-order functional programs, we develop a notion of constrained Horn clauses in higher-order logic and a decision problem concerning their satisfiability. We show that, although satisfiable systems of higher-order clauses do not generally have least models, there is a notion of canonical model obtained through a reduction to a problem ...

متن کامل

Synchronizing Constrained Horn Clauses

Simultaneous occurrences of multiple recurrence relations in a system of non-linear constrained Horn clauses are crucial for proving its satisfiability. A solution of such system is often inexpressible in the constraint language. We propose to synchronize recurrent computations, thus increasing the chances for a solution to be found. We introduce a notion of CHC product allowing to formulate a ...

متن کامل

Solving Constrained Horn Clauses Using Dependence-Disjoint Expansions

Recursion-free Constrained Horn Clauses (CHCs) are logicprogramming problems that formulate verifying safety of programs with bounded iteration and recursion. They both formulate bounded verification problems and are generated by solvers that attempt to verify safety of unbounded iterative or recursive systems. Efficient solvers of recursion-free systems reduce the problem to solving a series o...

متن کامل

Solving Existentially Quantified Horn Clauses

Temporal verification of universal (i.e., valid for all computation paths) properties of various kinds of programs, e.g., procedural, multi-threaded, or functional, can be reduced to finding solutions for equations in form of universally quantified Horn clauses extended with well-foundedness conditions. Dealing with existential properties (e.g., whether there exists a particular computation pat...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

ژورنال

عنوان ژورنال: Proceedings of the ACM on programming languages

سال: 2022

ISSN: ['2475-1421']

DOI: https://doi.org/10.1145/3498722