Equivalence Checking By Logic Relaxation

Slides:



Advertisements
Similar presentations
The Synthesis of Cyclic Circuits with SAT and Interpolation By John Backes and Marc Riedel ECE University of Minnesota.
Advertisements

Comparative Succinctness of KR Formalisms Paolo Liberatore.
SMT Solvers (an extension of SAT) Kenneth Roe. Slide thanks to C. Barrett & S. A. Seshia, ICCAD 2009 Tutorial 2 Boolean Satisfiability (SAT) ⋁ ⋀ ¬ ⋁ ⋀
Aaron Bradley University of Colorado, Boulder
INHERENT LIMITATIONS OF COMPUTER PROGRAMS CSci 4011.
A failed attempt to optimize variable ordering with tools for Constraints Solving Edmund ClarkeOfer Strichman Carnegie Mellon University.
Quantifier Elimination Via Clause Redundancy Eugene Goldberg, Pete Manolios Northeastern University, USA FMCAD-2013, October 20-23, Portland, OR, USA.
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:
Interpolants [Craig 1957] G(y,z) F(x,y)
1 Satisfiability Modulo Theories Sinan Hanay. 2 Boolean Satisfiability (SAT) Is there an assignment to the p 1, p 2, …, p n variables such that  evaluates.
1 Polynomial Church-Turing thesis A decision problem can be solved in polynomial time by using a reasonable sequential model of computation if and only.
. PGM 2002/3 – Tirgul6 Approximate Inference: Sampling.
Instructor Neelima Gupta
On Bridging Simulation and Formal Verification Eugene Goldberg Cadence Research Labs (USA) VMCAI-2008, San Francisco, USA.
INTRODUCTION TO ARTIFICIAL INTELLIGENCE COS302 MICHAEL L. LITTMAN FALL 2001 Satisfiability.
Toggle Equivalence Preserving (TEP) Logic Optimization Eugene Goldberg (Cadence), Kanupriya Gulati (Texas A&M University) Sunil Khatri (Texas A&M University)
Advanced Topics in Propositional Logic Chapter 17 Language, Proof and Logic.
Incremental formal verification of hardware Hana Chockler Alexander Ivrii Arie Matsliah Shiri Moran Ziv Nevo IBM Research - Haifa.
FPGA PLB Evaluation using Quantified Boolean Satisfiability Andrew C. Ling M.A.Sc. Candidate University of Toronto Deshanand P. Singh Ph.D. Altera Corporation.
Lazy Annotation for Program Testing and Verification Speaker: Chen-Hsuan Adonis Lin Advisor: Jie-Hong Roland Jiang November 26,
Simultaneously Learning and Filtering Juan F. Mancilla-Caceres CS498EA - Fall 2011 Some slides from Connecting Learning and Logic, Eyal Amir 2006.
Cut-Based Inductive Invariant Computation Michael Case 1,2 Alan Mishchenko 1 Robert Brayton 1 Robert Brayton 1 1 UC Berkeley 2 IBM Systems and Technology.
SAT Sweeping with Local Observability Don’t-Cares Qi Zhu 1 Nathan Kitchen 1 Andreas Kuehlmann 1,2 Alberto Sangiovanni-Vincentelli 1 1 University of California.
Properties Incompleteness Evaluation by Functional Verification IEEE TRANSACTIONS ON COMPUTERS, VOL. 56, NO. 4, APRIL
Generating High-Quality Tests for Boolean Circuits by Treating Tests as Proof Encoding Eugene Goldberg, Pete Manolios Northeastern University, USA TAP-2010,
SAT-Based Model Checking Without Unrolling Aaron R. Bradley.
A Decision-Making Procedure for Resolution-Based SAT-solvers Eugene Goldberg Cadence Research Labs (USA) SAT-2008, Guangzhou, P.R. China.
2009/6/30 CAV Quantifier Elimination via Functional Composition Jie-Hong Roland Jiang Dept. of Electrical Eng. / Grad. Inst. of Electronics Eng.
CPSC 121: Models of Computation REVIEW. Course Learning Outcomes You should be able to: – model important problems so that they are easier to discuss,
P & NP.
The Analysis of Cyclic Circuits with Boolean Satisfiability
Synthesis for Verification
Alan Mishchenko UC Berkeley
Solving Linear Arithmetic with SAT-based MC
Enhancing PDR/IC3 with Localization Abstraction
New Directions in the Development of ABC
Alan Mishchenko Robert Brayton UC Berkeley
Alan Mishchenko Satrajit Chatterjee Robert Brayton UC Berkeley
Satisfiability Modulo Theories
A Semi-Canonical Form for Sequential AIGs
Synthesis for Verification
Optimal Redundancy Removal without Fixedpoint Computation
LPSAT: A Unified Approach to RTL Satisfiability
Property Directed Reachability with Word-Level Abstraction
Introduction to Formal Verification
Polynomial Construction for Arithmetic Circuits
Canonical Computation without Canonical Data Structure
ECE 667 Synthesis and Verification of Digital Circuits
Canonical Computation Without Canonical Data Structure
Robert Brayton UC Berkeley
This Lecture Substitution model
Automated Extraction of Inductive Invariants to Aid Model Checking
Improvements to Combinational Equivalence Checking
SAT-based Methods for Scalable Synthesis and Verification
GLA: Gate-Level Abstraction Revisited
Research Status of Equivalence Checking at Zhejiang University
Resolution Proofs for Combinational Equivalence
Recurrences (Method 4) Alexandra Stefan.
Canonical Computation without Canonical Data Structure
NP-COMPLETE Prof. Manjusha Amritkar Assistant Professor Department of Information Technology Hope Foundation’s International Institute of Information.
This Lecture Substitution model
Recording Synthesis History for Sequential Verification
Canonical Computation without Canonical Data Structure
A Practical Approach to Arithmetic Circuit Verification
This Lecture Substitution model
SAT-based Methods: Logic Synthesis and Technology Mapping
Faster Extraction of High-Level Minimal Unsatisfiable Cores
Integrating AIG Package, Simulator, and SAT Solver
Verifying Clausal Proofs, DRUPing and Interpolants SAT/SMT Seminar
Presentation transcript:

Equivalence Checking By Logic Relaxation Eugene Goldberg FMCAD, Mountain View, CA, USA October 3-6, 2016

Outline Introduction Equivalence checking by logic relaxation Experimental results and conclusions

Motivation Equivalence Checking (EC) is an important part of formal verification Any progress in EC empowers logic synthesis Short EC proofs for structurally similar circuits Ideas of EC of combinational circuits can be re-used in EC of sequential circuits and software

Solving EC z' z" N" N' … … X' X" EQ(X',X" ) Prove EQ  Grlx  (z'  z"), N" N' where Grlx = FN'  FN" This reduces to proving EQ  Grlx  ~(z' z") UNSAT … … X' X" EQ(X',X" ) EQ(x',x" ) = 1, iff x' = x"

Cut Image N' N" q' q" Cut … … x' x" EQ(X',X" ) Let Imgcut specify the cut image N' N" q' q" Cut Imgcut(q',q")=0, iff there is no input (x',x"), x' = x" for which N',N" produce (q',q") … … Let Cut = {z',z"}. N' and N" are equivalent iff Imgcut  (z'  z"), x' x" EQ(X',X" )

Problem To Solve: Finding an Inductive Proof Of Equivalence z' z" Given combin. circuits N' and N", find formulas Hi such that Cutk … Imgi  Hi , 0 ≤ i < k Hi are as simple as possible Hi can be derived from Hi-1 Hk  Imgk(z',z") Cuti … Cut0 … … X' X" A simple inductive proof should exist if N' and N" are struct. similar

Some Background Building inductive proofs of equivalence Berman, Trevillyan 1988 Brand 1993 Kuehlmann, Krohm 1996 Goldberg, Prasad, Brayton 2001 Mishchenko,Chatterjee,Brayton,Een 2006 Proofs are based on derivation of pre-defined relations e.g. equivalences

Outline Introduction Equivalence checking by logic relaxation Experimental results and conclusions

Structure Of Cut Image z' z" Assignments excluded from cut image: Sexcl = Srlx U Simp z' z" Srlx = {(q',q") | only relaxed inputs (x',x") where x' ≠ x" can produce (q',q") } Simp = {(q',q") | no input (x',x") can produce (q',q") } q' Cut q" … … X' X" (q',q")  Simp iff q' cannot be produced in N' and/or q" cannot be produced in N" EQ(X',X" )

Definition Of Boundary Formulas EC by Logic Relaxation: “replace” Imgcut with boundary formula Hcut Boundary formula Hcut : If (q',q")  Srlx , then Hcut(q',q") = 0 If (q',q")  Simp , then Hcut(q',q") can take an arbitrary value Imgcut  Hcut

Boundary Formula for Cut = {z',z" } Assume that N' and N" are not constants Cut N' N" Simp=  Sexcl = Srlx … … Hcut  Imgcut X' X" EQ(X',X" ) Testing if N' is a constant: two easy SAT checks

Boundary Formula And Partial Quantifier Elimination Complete Quantif. Elimin. Imgcut  W [ EQ FM] W = Vars(FM) \ Vars(Cut) N' N" Cut Partial Quantif. Elimin. M Hcut  W [ FM]  W [ EQ FM] … … x' x" EQ  Grlx  ~(z'  z") is equisat. with Hcut  Grlx  ~(z'  z") EQ(X',X" ) where Grlx = FN'  FN"

Contrasting Cut Image And Boundary Formulas Imgcut Cut Hcut Cut M M … … … … EQ(X',X" ) EQ(X',X" )

Boundary Formulas Of Structurally Similar Circuits Suppose,  v  Cut' v = gv(Lv) where Lv  Cut" N' N" Cut Cut' Cut" Let Maxcut be the largest value of Lv , v  Cut' … … x' Then Hcut can be built from (Maxcut + 1)-literal clauses x" EQ(X',X" )

EC By Logic Relaxation z' z" Cutk … Cuti Mi Cut0 … … X' X" Cut0 = X' X",...,Cutk={z',z“ } z' z" Compute H0,..,Hk Cutk where H0= EQ(X',X" ) … Hi  Wi [ FMi ]  Wi [Hi-1  FMi] Cuti Mi Wi = Vars(FMi ) \ Vars(Cuti) Cut0 If Hk  (z'  z"), N' and N" are equivalent … … X' X" If, say, Hk(z' =0,z"=1)=1 and N', N" can produce 0 and 1, they are inequivalent

Outline Introduction Equivalence checking by logic relaxation Experimental results and conclusions

Non-Trivial Example Of EC Mlps computes a median bit of an s-bit multiplier Operands A and B where A={a1,..,as}, B={b1,...,bs} h is an additional input variable If h=1, then N' and N" compute Mlps if h=0, then N' and N" evaluate to 0

Comparison With ABC FMi specifies logic below i-th cut Partial Quantifier Elimination (a variation of HVC-14 algorithm) is based on machinery of D-sequents (FMCAD-12 , FMCAD-13) ABC is a high-quality tool developed at UC, Berkeley val. of s in Mlps #cuts EC by LoR (s.) ABC (s.) 10 37 4.5 11 41 7.1 38 12 45 142 13 49 16 757 14 53 25 3,667 15 57 40 11,237 61 70 > 6 h Formulas Hi were comp-uted approximately Hi  Wi [ FMi ]  Wi [Hi-1  FMi] FMi specifies logic below i-th cut Only a subset of clauses of FMi was used

Proving Inequivalence Formula  EQ(X',X")  FN'  FN"  ~(z' z") Formula  H3  FN'  FN"  ~(z' z") Formula H3 was computed precisely Sat-solver : Minisat 2.0, Time limit: 600 s Form. type #solved total time (s) median  95 > 3,490 4.2  100 1,030 1.0

Conclusions Relative_complexity(N',N") << Absolute_complexity(N',N") EC by logic relaxation gives a general solution It can be extended to sequential circuits/programs Efficient partial quantifier elimination is of great value