1 / 33

Linear Quantifier Elimination as an Abstract Decision Procedure

Linear Quantifier Elimination as an Abstract Decision Procedure. Nikolaj Bjørner Microsoft Research. What, Why and How. What Why – actually SMT Applications use Quantifiers How Interleave Quantifier-Elimination steps with DPLL(T) loop. . Linear QE is cool and macho .

edmund
Download Presentation

Linear Quantifier Elimination as an Abstract Decision Procedure

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Linear Quantifier Elimination as an Abstract Decision Procedure Nikolaj Bjørner Microsoft Research

  2. What, Why and How What Why – actually SMT Applications use Quantifiers How Interleave Quantifier-Elimination steps with DPLL(T) loop.

  3. Linear QE is cool and macho Bug found by SLAyer using Z3’s QE procedure Should we call it Quantifier Termination?

  4. Linear QE is CLASSICAL Long history: • Presburger, Büchi, Cooper, Oppen, Fischer&Rabin, Pugh, Klaedtke, Boudet&Comon, Boigelot&Wolper, … Many tools: • REDLOG, -package, QEPCAD, LIRA, LDD, LASH, MONA, Mjolnir, Isabelle, HOL-light, ….

  5. A Rough Picture of Current Approach FourierMotzkin Resolution Omega Test Case split+ Virtualsubst Loos-Weispfenning Cooper Case split+ Resolution Abstract DecisionProc Abstract DecisionProc

  6. Opportunity • SMT solvers use are good at Boolean combinations of quantifier free formulas. is SAT

  7. Opportunity All-SMT enumerates satisfiable branches has 8 satisfiable cases. Shorter than

  8. Opportunity All-SMT enumerates satisfiable branches Can be used for DNF enumeration • For QE procedures tuned to DNF • [MonniauxLPAR 2008] • Minimize monomes • Compares several different QE procedures • Also suggested in [de Moura, Ruess, Sorea CAV 2003]

  9. Opportunity Linear Quantifier Elimination in Verification SLAyer: A Separation Logic Prover Y Symbolic Execution and Abstraction Predicate Abstraction: • [Chaki, Gurfinkel, StrichmannFMCAD 09] • Linear Decision Diagrams LDD

  10. Any news? • Virtual Substitutions = Bounds + Resolution • Embed QE case splits into DPLL(LA) • A new twist on Presburger QE: • Cooper + Resolution from the -test • Distributed Divisibility Constraints • Practicalities: • Use LA solvers to prune search early • Solve integer equalities • Parallel vs. Sequential Elimination • Handling finite range arithmeticefficiently

  11. Loos-Weispfenning Abstract QE(LRA) Terms Atoms Formulas

  12. Loos-Weispfenning Abstract QE(LRA) Terms Atoms Formulas

  13. Loos-Weispfenning Abstract QE(LRA) Terms Atoms Formulas

  14. Loos-Weispfenning Abstract QE(LRA) Terms Atoms Formulas

  15. Loos-Weispfenning Abstract QE(LRA) Terms Atoms Formulas

  16. Loos-Weispfenning Abstract QE(LRA) Terms Atoms Formulas

  17. Loos-Weispfenning Abstract QE(LRA) Terms Atoms Formulas

  18. Loos-Weispfenning Abstract QE(LRA) Terms Atoms Formulas

  19. Loos-Weispfenning Abstract QE(LRA)

  20. Loos-Weispfenning Abstract QE(LRA)

  21. The Abstract Decision Procedure Non-chronological backtracking works across elimination splits decide decide propagate decide Eliminate x [x↦φ

  22. Cooper+ Abstract QE(LIA) Terms Atoms Formulas

  23. Cooper+ Abstract QE(LIA)

  24. Cooper+ Abstract QE(LIA) Resolving integer inequalities: n x m-ary version in [Pugh 92]

  25. Cooper+ Abstract QE(LIA) Eliminating divisibility

  26. Practicalities Use LA solvers to prune search early • Efficient LA solvers eliminate infeasible cases • Identify satisfiable pure formulas Linear Diophantine Equation solving, e.g., [Pugh 92] Elimination Order: Sequential vs. Parallel Handling finite range arithmetic efficiently • In context of Z3: Reduce finite range arithmetic to bit-vector theory

  27. Selective Experiments • FM/-SMS: All-SMT loop +Fourier-Motzkin elimination • LW/C-SMT: All-SMT loop +Cooper/LW elimination • LW/C-Plain: Only SMT on pure formulas. • Mix-Model: Use Model to guide split. • Mix-SMT: Method presented here. Would have been much worse without SMT on pure formulas SMT is a waste of time on random formulas Mix-SMT cheaper than DNF based branching

  28. Summary Linear Quantifier Eliminination Integrated as an abstract decision procedure. Similar procedures for other theories: • Term Algebras • Arrays (very partially) Available in Z3 using ELIM_QUANTIFIERS=true

  29. Term Algebra (and co-term algebras) Terms Atoms Formulas

More Related