Faster Extraction of High-Level Minimal Unsatisfiable Cores

Slides:



Advertisements
Similar presentations
Automated abstraction refinement II Heuristic aspects Ken McMillan Cadence Berkeley Labs.
Advertisements

The behavior of SAT solvers in model checking applications K. L. McMillan Cadence Berkeley Labs.
Exploiting SAT solvers in unbounded model checking
Exploiting SAT solvers in unbounded model checking K. L. McMillan Cadence Berkeley Labs.
Hybrid BDD and All-SAT Method for Model Checking Orna Grumberg Joint work with Assaf Schuster and Avi Yadgar Technion – Israel Institute of Technology.
1 Local Restarts in SAT Solvers Vadim Ryvchin and Ofer Strichman Technion, Haifa, Israel.
UIUC CS 497: Section EA Lecture #2 Reasoning in Artificial Intelligence Professor: Eyal Amir Spring Semester 2004.
Proofs from SAT Solvers Yeting Ge ACSys NYU Nov
Technion 1 Generating minimum transitivity constraints in P-time for deciding Equality Logic Ofer Strichman and Mirron Rozanov Technion, Haifa, Israel.
Daniel Kroening and Ofer Strichman 1 Decision Procedures An Algorithmic Point of View SAT.
1/30 SAT Solver Changki PSWLAB SAT Solver Daniel Kroening, Ofer Strichman.
IBM Labs in Haifa © 2005 IBM Corporation Adaptive Application of SAT Solving Techniques Ohad Shacham and Karen Yorav Presented by Sharon Barner.
ULTIMATELY INCREMENTAL SAT Alexander Nadel 1, Vadim Ryvchin 1,2, and Ofer Strichman 2 1 – Intel, Haifa, Israel 2 – Technion, Haifa, Israel SAT’14, Vienna,
Reduction of Interpolants for Logic Synthesis John Backes Marc Riedel University of Minnesota Dept.
SAT and Model Checking. Bounded Model Checking (BMC) A.I. Planning problems: can we reach a desired state in k steps? Verification of safety properties:
Boosting Minimal Unsatisfiable Core Extraction. Agenda Introduction and motivation New algorithms ◦ Generic scheme ◦ Resolution-based algorithm ◦ Selector-variable-based.
Weizmann Institute Tuning SAT-checkers for Bounded Model-Checking A bounded guided tour Ofer Shtrichman Weizmann Institute & IBM (HRL)
Proof-based Abstraction Presented by Roman Gershman Ken McMillan, Nina Amla.
On-The-Fly Resolve Trace Minimization Ohad Shacham and Karen Yorav IBM Haifa Research Laboratory.
Presented by Ed Clarke Slides borrowed from P. Chauhan and C. Bartzis
GRASP-an efficient SAT solver Pankaj Chauhan. 6/19/ : GRASP and Chaff2 What is SAT? Given a propositional formula in CNF, find an assignment.
Efficient SAT Solving for Non- clausal Formulas using DPLL, Graphs, and Watched-cuts Himanshu Jain Edmund M. Clarke.
1 Linear-time Reductions of Resolution Proofs Omer Bar-Ilan Oded Fuhrmann Shlomo Hoory Ohad Shacham Ofer Strichman Technion.
Technion 1 Generating minimum transitivity constraints in P-time for deciding Equality Logic Ofer Strichman and Mirron Rozanov Technion, Haifa, Israel.
GRASP SAT solver Presented by Constantinos Bartzis Slides borrowed from Pankaj Chauhan J. Marques-Silva and K. Sakallah.
Formal Verification Group © Copyright IBM Corporation 2008 IBM Haifa Labs SAT-based unbounded model checking using interpolation Based on a paper “Interpolation.
Technion 1 (Yet another) decision procedure for Equality Logic Ofer Strichman and Orly Meir Technion.
Computing Over­Approximations with Bounded Model Checking Daniel Kroening ETH Zürich.
1 Abstraction Refinement for Bounded Model Checking Anubhav Gupta, CMU Ofer Strichman, Technion Highly Jet Lagged.
SAT Solving Presented by Avi Yadgar. The SAT Problem Given a Boolean formula, look for assignment A for such that.  A is a solution for. A partial assignment.
1 Linear-time Reductions of Resolution Proofs Omer Bar-Ilan Oded Fuhrmann Shlomo Hoory Ohad Shacham Ofer Strichman Technion.
7/13/2003BMC A SAT-Based Approach to Abstraction Refinement in Model Checking Bing Li, Chao Wang and Fabio Somenzi University of Colorado at Boulder.
On Bridging Simulation and Formal Verification Eugene Goldberg Cadence Research Labs (USA) VMCAI-2008, San Francisco, USA.
1 Automatic Refinement and Vacuity Detection for Symbolic Trajectory Evaluation Orna Grumberg Technion Haifa, Israel Joint work with Rachel Tzoref.
Solvers for the Problem of Boolean Satisfiability (SAT) Will Klieber Aug 31, 2011 TexPoint fonts used in EMF. Read the TexPoint manual before you.
Incremental formal verification of hardware Hana Chockler Alexander Ivrii Arie Matsliah Shiri Moran Ziv Nevo IBM Research - Haifa.
On the Relation between SAT and BDDs for Equivalence Checking Sherief Reda Rolf Drechsler Alex Orailoglu Computer Science & Engineering Dept. University.
Boolean Satisfiability Present and Future
SAT 2009 Ashish Sabharwal Backdoors in the Context of Learning (short paper) Bistra Dilkina, Carla P. Gomes, Ashish Sabharwal Cornell University SAT-09.
February 22-25, 2010 Designers Work Less with Quality Formal Equivalence Checking by Orly Cohen, Moran Gordon, Michael Lifshits, Alexander Nadel, and Vadim.
Efficient SAT Solving Under Assumptions Alexander Nadel 1 and Vadim Ryvchin 1,2 1 – Intel, Haifa, Israel 2 – Technion, Haifa, Israel SAT’12, Trento, Italy.
Preprocessing in Incremental SAT Alexander Nadel 1, Vadim Ryvchin 1,2, and Ofer Strichman 2 1 – Intel, Haifa, Israel 2 – Technion, Haifa, Israel SAT’12,
SAT Solving As implemented in - DPLL solvers: GRASP, Chaff and
1 Alan Mishchenko Research Update June-September 2008.
Enhancing Model Checking Engines for Multi-Output Problem Solving Alan Mishchenko Robert Brayton Berkeley Verification and Synthesis Research Center Department.
© 2012 IBM Corporation Perfect Hashing and CNF Encodings of Cardinality Constraints Yael Ben-Haim Alexander Ivrii Oded Margalit Arie Matsliah SAT 2012.
Efficient Generation of Small Interpolants in CNF (for Model Checking)
Hybrid BDD and All-SAT Method for Model Checking
Abstraction and Refinement for Large Scale Model Checking
Minimizing Unsatisfiable Formulas
Parallelism in SAT Solvers
Recovering and Exploiting Structural Knowledge from CNF Formulas
Alan Mishchenko UC Berkeley
Deriving small unsatisfiable cores with dominators
Mining backbone literals in incremental SAT
Property Directed Reachability with Word-Level Abstraction
SAT-Based Area Recovery in Technology Mapping
Canonical Computation without Canonical Data Structure
Canonical Computation Without Canonical Data Structure
Decision Procedures An Algorithmic Point of View
A Progressive Approach for Satisfiability Modulo Theories
Resolution Proofs for Combinational Equivalence
Efficient MUS Extraction with Resolution
Canonical Computation without Canonical Data Structure
Canonical Computation without Canonical Data Structure
Decision heuristics based on an Abstraction/Refinement model
SAT-based Methods: Logic Synthesis and Technology Mapping
GRASP-an efficient SAT solver
Verifying Clausal Proofs, DRUPing and Interpolants SAT/SMT Seminar
Presentation transcript:

Faster Extraction of High-Level Minimal Unsatisfiable Cores Ryvchin Vadim and Ofer Strichman Technion, Israel SAT’11 Conference Ann Arbor, USA June 21, 2011

Agenda Introduction and motivation Optimizations Experimental results A. Partial Resolution B. Selective clause minimization C . Postponed IC-propagation E. Selective learning of IC-clauses G. Removal Strategy Experimental results Resolution vs. Selector variables

High-Level UC Given: A set of interesting constraints (IC)  = { IC1, IC2 , …, ICm }, and The remainder  The set    is a high-level UC (HLUC) if    is unsatisfiable HLUC is minimal (HLMUC) if removal of any IC makes    satisfiable

Examples Abstraction-refinement in model checking [MA’03] Latches in core define the next abstraction. Compositional Formal Equivalence Checking (FEC) [CGLNR’10] Decompose the compared circuits to blocks. Assume inputs to blocks are the same Assumptions in the core need to be proved. A very popular model checking technique is based on abstraction/refinement. A BDD-based model checker checks an abstract model, where the abstraction is defined by the set of latches that we replace with free inputs. B. If the property fails, a SAT solver is ran on the concrete model to the depth of the ce. C. If there is no BUG - the latches that participate in the proof define the abstraction in the next iteration. D: clearly, then we want to have as few latches in the proof as possible

Traditional UC Extraction: Stage 1: Translate to Clauses An interesting constraint The remainder (the rest of the formula) Each small square is a propositional clause, e.g. (a + b’)

Traditional UC Extraction: Stage 2: Extract a Clause-Level UC An interesting constraint The remainder (the rest of the formula) Colored squares belong to the clause-level UC

Traditional UC Extraction: Stage 3: Map UC back to ICs An interesting constraint The remainder (the rest of the formula) The UC contains three interesting constraints!

A Mismatch between Mainstream Research and the Needs of Real-World Applications Real-world applications: reduce # interesting constraints in the core Latches/gates for abstraction refinement Assumptions for compositional FEC Vast majority of existing algorithms: reduce # of clauses in the core 19/21 papers on UC extraction only consider clause-level UC extraction

Small/Minimal Clause-Level UC  Small/Minimal High-Level UC A small clause-level UC, but the high-level UC is the largest possible: A large clause-level UC, but the high-level UC is empty:

Resolution Refutation C22 C23=() C17 C18 C19 C20 C21 C10 C11 C12 C13 C14 C15 C16 C1 C2 C3 C4 C5 C6 C7 C8 C9 Legend: Input clauses Derived clauses

Resolution Refutation C22 C23=() C17 C18 C19 C20 C21 C10 C11 C12 C13 C14 C15 C16 C1 C2 C3 C4 C5 C6 C7 C8 C9 Legend: Input clauses Derived clauses Empty clause cone: { C4 C5 C6 C7 C13 C14 C19 C20 C23 } Unsat Core: { C4 C5 C6 C7 }

Resolution Refutation C22 C23=() C17 C18 C19 C20 C21 C10 C11 C12 C13 C14 C15 C16 C1 C2 C3 C4 C5 C6 C7 C8 C9 Legend: Empty Clause Cone Unsat Core Empty clause cone: { C4 C5 C6 C7 C13 C14 C19 C20 C23 } Unsat Core: { C4 C5 C6 C7 }

Resolution with ICs C22 C23=() C17 C18 C19 C20 C21 C10 C11 C12 C13 C14 Legend: Input Clauses IC1 IC2 Remainder Derived Clauses Derived clauses

Resolution with ICs C22 C23=() C17 C18 C19 C20 C21 C10 C11 C12 C13 C14 Legend: Input Clauses IC1 IC2 Remainder Derived Clauses IC1 IC2 Remainder

HLUC C22 C23=() C17 C18 C19 C20 C21 C10 C11 C12 C13 C14 C15 C16 C1 C2 Legend: IC1 IC2 Remainder HLUC: { IC2 }

HLMUC Algorithm [N’10] Solve  Æ  ’ = HLUC = ’  =  \ ICi UNSAT SAT Remove one ICi ϵ  that wasn’t already removed  No unchecked ICs  - remainder,  - ICs Initialization: ’ =  =  Assumption:  Æ  is UNSAT

Contribution of this Work Seven optimizations for single HLMUC. improved run time and smaller HLMUC Comparison between resolution and selector variables solvers.

A. Partial Resolution Observations: Suggestion: Result: IC-clauses usually between 5-15% of the problem clauses We do not need the whole resolution table Suggestion: Keep only clauses relevant to IC resolutions Result: The size of the resolution graph reduced Very effective on large CNFs

A. Partial Resolution C22 C23=() C17 C18 C19 C20 C21 C10 C11 C12 C13 Legend: IC1 IC2 Remainder

A. Partial Resolution C22 C23=() C17 C18 C19 C20 C21 C10 C11 C12 C13 Legend: IC1 IC2 Not Needed

A. Partial Resolution C22 C23=() C17 C20 C21 C10 C15 C16 C1 C7 C8 Legend: IC1 IC2

A. Partial Resolution - Summary C22 C23=() C17 C20 C21 C10 C15 C16 C1 C7 C8 Legend: IC1 IC2 Keep only the needed resolutions

B. Selective clause minimization Technique for shrinking conflict clauses The algorithm is based on traversing the resolution DAG backward from each literal in the learned clause The problem: May turn a non-IC-clause into a shorter IC-clause

B. Selective clause minimization c1= (¬v1 Ç v2) c2= (¬v2 Ç v3) c3= (¬v4 Ç v5) c4= (¬v5 Ç v6) c5= (¬v1 Ç ¬v3 Ç ¬v4 Ç ¬v6)

B. Selective clause minimization c1= (¬v1 Ç v2) c2= (¬v2 Ç v3) c3= (¬v4 Ç v5) c4= (¬v5 Ç v6) c5= (¬v1 Ç ¬v3 Ç ¬v4 Ç ¬v6) c1 c2 v1 v2 v3

B. Selective clause minimization c1= (¬v1 Ç v2) c2= (¬v2 Ç v3) c3= (¬v4 Ç v5) c4= (¬v5 Ç v6) c5= (¬v1 Ç ¬v3 Ç ¬v4 Ç ¬v6) c1 c2 v1 v2 v3 c5 c5 ¬v6 c5 v4 c3 c4 v5 v6

B. Selective clause minimization c1= (¬v1 Ç v2) c2= (¬v2 Ç v3) c3= (¬v4 Ç v5) c4= (¬v5 Ç v6) c5= (¬v1 Ç ¬v3 Ç ¬v4 Ç ¬v6) c1 c2 v1 v2 v3 c5 c5 ¬v6 c5 v4 c3 c4 v5 v6

B. Selective clause minimization c1= (¬v1 Ç v2) c2= (¬v2 Ç v3) c3= (¬v4 Ç v5) c4= (¬v5 Ç v6) c5= (¬v1 Ç ¬v3 Ç ¬v4 Ç ¬v6) 1-UIP based conflict analysis: c6= (¬v1 Ç ¬v3 Ç ¬v4) c1 c2 v1 v2 v3 c5 c5 ¬v6 c5 v4 c3 c4 v5 v6

B. Selective clause minimization c1= (¬v1 Ç v2) c2= (¬v2 Ç v3) v1  v3 ¬v3  ¬v1

B. Selective clause minimization c1= (¬v1 Ç v2) c2= (¬v2 Ç v3) c6= (¬v1 Ç ¬v3 Ç ¬v4) c6= (¬v1 Ç ¬v4) v1  v3 ¬v3  ¬v1

B. Selective clause minimization c1= (¬v1 Ç v2) c2= (¬v2 Ç v3) c3= (¬v4 Ç v5) c4= (¬v5 Ç v6) c5= (¬v1 Ç ¬v3 Ç ¬v4 Ç ¬v6) c6= (¬v1 Ç ¬v4) c1 c2 v1 v2 v3 c5 c5 ¬v6 c5 v4 c3 c4 v5 v6

B. Selective clause minimization c1= (¬v1 Ç v2) c2= (¬v2 Ç v3) (IC) c3= (¬v4 Ç v5) c4= (¬v5 Ç v6) c5= (¬v1 Ç ¬v3 Ç ¬v4 Ç ¬v6) c1 c2 v1 v2 v3 c5 c5 ¬v6 c5 v4 c3 c4 v5 v6

B. Selective clause minimization c1= (¬v1 Ç v2) c2= (¬v2 Ç v3) (IC) With minimization using c2: c6= (¬v1 Ç ¬v4) (IC) Without minimization: c6= (¬v1 Ç ¬v3 Ç ¬v4) (remainder)

B. Selective clause minimization Suggested solution: Disable minimization if it adds dependency on IC-clause. c6= (¬v1 Ç ¬v3 Ç ¬v4) instead of c6= (¬v1 Ç ¬v4) Disabling minimization  reduces #derived IC-clauses  reduces #IC-clauses in UC and finds HLMUC faster

C. Postpone IC-propagations Change BCP order Run BCP Conflict Analyze Conflict no implications Next Operations

C. Postpone IC-propagations Change BCP order Run BCP over non IC-clause Conflict Analyze Conflict found implication no implications Propagate a single IC-clause Conflict no implications Next Operations

C. Postpone IC-propagations Increase chances to get conflicts in remainder Decreases number of derived IC-clauses Decreases number of IC-clauses in UC.

E. Selective Learning implication IC-clause implication X @2 @2 @5 @5 @3 @3

E. Selective Learning implication IC-clause implication X @2 @2 @5 @5 @3 @3

E. Selective Learning implication IC-clause implication X @2 @2 @5 @5 @5 @5 @5 @5 @5 X @5 @5 @5 @3 @3 Learnt clause should be marked “IC-clause”

E. Selective Learning We refrain from learning IC-clauses Instead, do not learn it learn a (non-asserting) remainder clause make a decision How ?

E. Selective Learning How ? Treat the last IC-clause implication as decision Perform new 1-UIP conflict analysis The learnt clause is ‘remainder’

E. Selective Learning implication IC-clause implication X @2 @2 @5 @5 @3 @3

E. Selective Learning implication IC-clause implication X @2 @2 @5 @5 @6 @5 @5 @6 X @5 @5 @6 @3 @3

E. Selective Learning implication IC-clause implication X @2 @2 @5 @5 @6 @5 @5 @6 X @5 @5 @6 @3 @3

E. Selective Learning implication IC-clause implication X @2 @2 @5 @5 @6 @5 @5 @6 X @5 @5 @6 @3 @3

G. Removal Strategy Recall: Solve  Æ  ’ = HLUC = ’  =  \ ICi UNSAT SAT Remove one ICi ϵ  that wasn’t already removed  No unchecked ICs Recall: In each iteration one IC is chosen to be removed.

G. Removal Strategy What is the effect of the removal order? Which IC should we remove first?

G. Removal Strategy Criterion: #clauses in UC Choose the one that contains least clauses in UC If UNSAT (not necessary), will converge faster If UNSAT (not necessary), will likely allow further removals that contains most clauses in UC If SAT (necessary), clauses are added as ‘remainder’ fast

Experimental Results Benchmark Set: Machines: Industrial set of problems from Intel Average #clauses = 2,572,270 Average #ICs = 3804 Average #IC-clauses = 96568 (6% of #clauses) Machines: Intel® Xeon® 4Ghz 32Gb of memory

Experimental Results

Experimental Results (zoom)

Experimental Results Improves N’10: Time: 44913 sec vs. 20453 sec (x2.19 speedup) HLMUC size: 18995 vs. 5090 (73.2% reduction)

Resolution vs. Selector variables Main cause for performance gap: clause minimization. When clause minimization is off: similar results (time + size of HLMUC). Selector variables: minimization does not turn non-IC- clause into IC-clause Selector variable prevents the minimization

Resolution vs. Selector variables c1= (¬v1 Ç v2) c2= (¬v2 Ç v3) (IC) c3= (¬v4 Ç v5) c4= (¬v5 Ç v6) c5= (¬v1 Ç ¬v3 Ç ¬v4 Ç ¬v6) c1 c2 v1 v2 v3 c5 c5 ¬v6 c5 v4 c3 c4 v5 v6

Resolution vs. Selector variables c1= (¬v1 Ç v2) c2= (¬v2 Ç v3 Ç ¬s) (IC) c3= (¬v4 Ç v5) c4= (¬v5 Ç v6) c5= (¬v1 Ç ¬v3 Ç ¬v4 Ç ¬v6) Selector variables are pure  cannot be removed  every IC-clause have at least one c1 c1 c2 c2 v1 v2 v3 c5 c5 ¬v6 c5 v4 c3 c4 v5 v6

Resolution vs. Selector variables Resolution-based: c1= (¬v1 Ç v2) c2= (¬v2 Ç v3) (IC) Selector-variables-based: c2= (¬v2 Ç v3 Ç ¬s) (IC) v1  v3 ¬v3  ¬v1 Cannot be resolved away v1  v3

Resolution vs. Selector variables

Resolution vs. Selector variables

Resolution vs. Selector variables Comparison to selector-variables: Time: 28032 sec vs. 20453 sec (x1.37 speedup) HLMUC size: 12090 vs. 5090 (57.8% reduction)

Thank You!