CHARME’03 Predicate abstraction with Minimum Predicates Sagar Chaki*, Ed Clarke*, Alex Groce*, Ofer Strichman** * Carnegie Mellon University ** Technion.

Slides:



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

Exploiting SAT solvers in unbounded model checking
Modeling issues Book: chapters 4.12, 5.4, 8.4, 10.1.
Abstraction in Model Checking Nishant Sinha. Model Checking Given a: –Finite transition system M –A temporal property p The model checking problem: –Does.
Delta Debugging and Model Checkers for fault localization
Introduction to Formal Methods for SW and HW Development 09: SAT Based Abstraction/Refinement in Model-Checking Roberto Sebastiani Based on work and slides.
Greta YorshEran YahavMartin Vechev IBM Research. { ……………… …… …………………. ……………………. ………………………… } T1() Challenge: Correct and Efficient Synchronization { ……………………………
SAT Based Abstraction/Refinement in Model-Checking Based on work by E. Clarke, A. Gupta, J. Kukula, O. Strichman (CAV’02)
Verification of Evolving Software Natasha Sharygina Joint work with Sagar Chaki and Nishant Sinha Carnegie Mellon University.
On Solving Presburger and Linear Arithmetic with SAT Ofer Strichman Carnegie Mellon University.
1 Regression-Verification Benny Godlin Ofer Strichman Technion.
© Anvesh Komuravelli Spacer Automatic Abstraction in SMT-Based Unbounded Software Model Checking Anvesh Komuravelli Carnegie Mellon University Joint work.
Panel on Decision Procedures Panel on Decision Procedures Randal E. Bryant Lintao Zhang Nils Klarlund Harald Ruess Sergey Berezin Rajeev Joshi.
Symmetry-Aware Predicate Abstraction for Shared-Variable Concurrent Programs Alastair Donaldson, Alexander Kaiser, Daniel Kroening, and Thomas Wahl Computer.
BLAST-A Model Checker for C Developed by Thomas A. Henzinger (EPFL) Rupak Majumdar (UC Los Angeles) Ranjit Jhala (UC San Diego) Dirk Beyer (Simon Fraser.
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:
Software Verification via Refinement Checking Sagar Chaki, Edmund Clarke, Alex Groce, CMU Somesh Jha, Wisconsin.
Using Statically Computed Invariants Inside the Predicate Abstraction and Refinement Loop Himanshu Jain Franjo Ivančić Aarti Gupta Ilya Shlyakhter Chao.
A … Framework for Verifying Concurrent C Programs Sagar Chaki Thesis Defense Talk.
1 Model Checking, Abstraction- Refinement, and Their Implementation Based on slides by: Orna Grumberg Presented by: Yael Meller June 2008.
State-Event Software Verification for Branching-Time Specifications Sagar Chaki, Ed Clarke, Joel Ouaknine, Orna Grumberg Natasha Sharygina, Tayssir Touili,
Scalable Error Detection using Boolean Satisfiability 1 Yichen Xie and Alex Aiken Stanford University.
Synergy: A New Algorithm for Property Checking
1 Predicate Abstraction of ANSI-C Programs using SAT Edmund Clarke Daniel Kroening Natalia Sharygina Karen Yorav (modified by Zaher Andraus for presentation.
1 Completeness and Complexity of Bounded Model Checking Ed Clarke Daniel Kroening Joel Ouaknine Carnegie Mellon University, Pittsburgh, USA Ofer Strichman.
SAT-Based Decision Procedures for Subsets of First-Order Logic
CS 267: Automated Verification Lectures 14: Predicate Abstraction, Counter- Example Guided Abstraction Refinement, Abstract Interpretation Instructor:
Predicate Abstraction for Software and Hardware Verification Himanshu Jain Model checking seminar April 22, 2005.
© 2007 Carnegie Mellon University Optimized L*-based Assume-Guarantee Reasoning Sagar Chaki, Ofer Strichman March 27, 2007.
1 Regression Verification: Proving the equivalence of similar programs Benny Godlin Ofer Strichman Technion, Haifa, Israel (This presentation is a subset.
1 Abstraction Refinement for Bounded Model Checking Anubhav Gupta, CMU Ofer Strichman, Technion Highly Jet Lagged.
1 A propositional world Ofer Strichman School of Computer Science, Carnegie Mellon University.
Formal Verification of SpecC Programs using Predicate Abstraction Himanshu Jain Daniel Kroening Edmund Clarke Carnegie Mellon University.
On Solving Presburger and Linear Arithmetic with SAT Ofer Strichman Carnegie Mellon University.
Model Checking for Embedded Systems Edmund Clarke, CMU High-Confidence Embedded Systems Workshop, May 1 st.
272: Software Engineering Fall 2012 Instructor: Tevfik Bultan Lecture 4: SMT-based Bounded Model Checking of Concurrent Software.
CSC2108 Lazy Abstraction on Software Model Checking Wai Sum Mong.
Verifying Concurrent Message- Passing C Programs with Recursive Calls Sagar Chaki, Edmund Clarke, Nicholas Kidd, Thomas Reps, and Tayssir Touili.
Tractable Symmetry Breaking Using Restricted Search Trees Colva M. Roney-Dougal, Ian P. Gent, Tom Kelsey, Steve Linton Presented by: Shant Karakashian.
By: Pashootan Vaezipoor Path Invariant Simon Fraser University – Spring 09.
1 Automatic Refinement and Vacuity Detection for Symbolic Trajectory Evaluation Orna Grumberg Technion Haifa, Israel Joint work with Rachel Tzoref.
272: Software Engineering Fall 2012 Instructor: Tevfik Bultan Lecture 3: Modular Verification with Magic, Predicate Abstraction.
Inferring Specifications to Detect Errors in Code Mana Taghdiri Presented by: Robert Seater MIT Computer Science & AI Lab.
Predicate Abstraction of ANSI-C Programs Using SAT By Edmund Clarke, Daniel Kroening, Natalia Sharygina, Karen Yorav Presented by Yunho Kim Provable Software.
Automated Patch Generation Adapted from Tevfik Bultan’s Lecture.
NP-Complete Problems. Running Time v.s. Input Size Concern with problems whose complexity may be described by exponential functions. Tractable problems.
Lecture 3 Algorithm Analysis. Motivation Which algorithm to use?
Author: Alex Groce, Daniel Kroening, and Flavio Lerda Computer Science Department, Carnegie Mellon University Pittsburgh, PA Source: R. Alur and.
Localization and Register Sharing for Predicate Abstraction Himanshu Jain Franjo Ivančić Aarti Gupta Malay Ganai.
Verification of Synchronization in SpecC Description with the Use of Difference Decision Diagrams Thanyapat Sakunkonchak Masahiro Fujita Department of.
Reachability for Linear Hybrid Automata Using Iterative Relaxation Abstraction Sumit K. Jha, Bruce H. Krogh, James E. Weimer, Edmund M. Clarke Carnegie.
SAT-Based Model Checking Without Unrolling Aaron R. Bradley.
CS357 Lecture 13: Symbolic model checking without BDDs Alex Aiken David Dill 1.
Variants of LTL Query Checking Hana ChocklerArie Gurfinkel Ofer Strichman IBM Research SEI Technion Technion - Israel Institute of Technology.
Error Explanation with Distance Metrics Authors: Alex Groce, Sagar Chaki, Daniel Kroening, and Ofer Strichman International Journal on Software Tools for.
1/20 Arrays Changki PSWLAB Arrays Daniel Kroening and Ofer Strichman Decision Procedure.
Verifying Component Substitutability Nishant Sinha Sagar Chaki Edmund Clarke Natasha Sharygina Carnegie Mellon University.
Finding bugs with a constraint solver daniel jackson. mandana vaziri mit laboratory for computer science issta 2000.
© Anvesh Komuravelli Spacer Model Checking with Proofs and Counterexamples Anvesh Komuravelli Carnegie Mellon University Joint work with Arie Gurfinkel,
Verifying Regular Behavior of C modules Sagar Chaki, Edmund Clarke, Alex Groce, CMU Somesh Jha, Wisconsin.
Counterexample-Guided Abstraction Refinement By Edmund Clarke, Orna Grumberg, Somesh Jha, Yuan Lu, and Helmut Veith Presented by Yunho Kim Provable Software.
Presentation Title 2/4/2018 Software Verification using Predicate Abstraction and Iterative Refinement: Part Bug Catching: Automated Program Verification.
SS 2017 Software Verification Bounded Model Checking, Outlook
Introduction to Software Verification
Property Directed Reachability with Word-Level Abstraction
Over-Approximating Boolean Programs with Unbounded Thread Creation
Automated Patch Generation
Predicate Abstraction
SAT Based Abstraction/Refinement in Model-Checking
Faster Extraction of High-Level Minimal Unsatisfiable Cores
Presentation transcript:

CHARME’03 Predicate abstraction with Minimum Predicates Sagar Chaki*, Ed Clarke*, Alex Groce*, Ofer Strichman** * Carnegie Mellon University ** Technion

Overview of MAGIC  Specification S expressed using Labeled Transition Systems (LTS)  Model M extracted from C programs using predicate abstraction (LTS)  Checks if S weakly simulates M For this talk consider trace containment  Supports most but not all of ANSI-C Pointers are handled by abstraction Recursion disallowed

Predicate abstraction int x,y L0:x = 1; L1:y = 1; L2:if (x == y) L3:y = 1; L4:elsey = 2; Control Flow Automaton

Predicate abstraction Control Flow Automaton Predicate inference

Predicate abstraction Predicate inferenceAbstract model

Counter Example Guided Abstraction Refinement Predicate Abstraction Abstract Model predicates Model Checking Yes Model P Property M  Counter Example  Counterexample concrete? Yes Refinement No More predicates No P = P ’

Example Existing methods accumulate predicates: Ideally we should choose (A == 0) A = 0; if(A == 0) B = 0; if(B == 0) ERRORC = 0; if(C == 0) ERROR No Yes CE1 CE1: (B == 0) or (A==0) CE2 CE2: (C == 0) or (A==0)

Optimization Problem  Given a set of Candidate Predicates CP, find a minimal subset p µ CP s.t. A ( M, CP ) ²  ! A ( M, p ) ²  If -- no predicates are necessary. Only luck… If -- not relevant

Counter Example Guided Abstraction Refinement Predicate Abstraction Abstract Model predicates Model Checking Yes Counter Example  Counterexample concrete? Yes Refinement No More Predicates No Model P Property M  P = P ’  T

Counter Example Guided Abstraction Refinement Predicate Abstraction Abstract Model predicates Model Checking Yes Counter Example  Counterexample concrete? Yes Refinement No Different Predicates No Model P Property M  P = P ’  T

A(M,P)² A(M,P)²  Yes Counter- example  Pass CP = Candidate Predicates P == CP Yes Undecided No Algorithm Sample and Eliminate T = T [  Find minimal P2CP that eliminates T Impossible possible P =   concrete Yes Fail No

Minimization problem  Given a set of spurious traces T A set of candidate predicates CP  Find the smallest subset p 2 CP that eliminates all traces in T (If impossible return ‘undecided’)

Solution with 0-1 ILP (or PBS)  Derive a mapping from each trace t 2 T to the set of sets of predicates in CP that eliminate it First…  Encode each predicate p 2 CP with a Boolean variable p b Second…

Solution with 0-1 ILP (or PBS)  Derive  s.t. every satisfying assignment to  corresponds to a set of predicates that eliminate T. Third…  Among all satisfying assignments, find the one that minimizes the number of selected predicates ( min  p b ) Fourth…

Solution with 0-1 ILP (or PBS)  Example Let { p 1, p 3 },{ p 2, p 3, p 5 } be the set of sets of predicates that eliminate t 1 Let { p 2, p 3 },{ p 3, p 4, p 7 } be the set of sets of predicates that eliminate t 2 Min  p i s.t. t 1 : (( p 1 Æ p 2 ) Ç ( p 2 Æ p 3 Æ p 5 )) Æ t 2 : (( p 2 Æ p 3 ) Ç ( p 3 Æ p 4 Æ p 7 ))

Avoiding an exponential no. of constraints  Try only combinations up to size k In almost all examples we tried, counterexample traces could be eliminated with individual predicates.  Use data flow analysis and only combine branches that are related

Experiments  Open SSL - 20 properties of the Handshake mechanism of Open SSL. On average 350 lines of C code per property after slicing  5 examples from the BLAST benchmark set

Comparison with BLAST  BLAST applies Lazy Abstraction Lazy abstraction is orthogonal to predicate minimization  BLAST looks for fix point of the loops (for a given set of predicates) with theorem prover calls Magic unrolls loops up to a given bound (Conclusion: Not an entirely fair comparison)

Results (time in sec.)

Number of predicates

Memory (MB)

Solution with 0-1 ILP (or PBS)  Let k ( t ), 0 · k ( t ) · 2 | cp | be the number of sets that eliminate t  Let l(t,i,j)2CP be the j th literal in the i th set (1 · i · k ( t )) that eliminates t. Third…