General Techniques for Symmetry Reduction in Model Checking Alastair Donaldson Alice Miller Department of Computing Science University of Glasgow.

Slides:



Advertisements
Similar presentations
1 Verification by Model Checking. 2 Part 1 : Motivation.
Advertisements

The SPIN System. What is SPIN? Model-checker. Based on automata theory. Allows LTL or automata specification Efficient (on-the-fly model checking, partial.
Automatic Verification Book: Chapter 6. How can we check the model? The model is a graph. The specification should refer the the graph representation.
Triangle partition problem Jian Li Sep,2005.  Proposed by Redstar in Algorithm board in Fudan BBS.  Motivated by some network design strategy.
CS 267: Automated Verification Lecture 8: Automata Theoretic Model Checking Instructor: Tevfik Bultan.
Lecture 24 MAS 714 Hartmut Klauck
CS 290C: Formal Models for Web Software Lecture 3: Verification of Navigation Models with the Spin Model Checker Instructor: Tevfik Bultan.
Automatic Verification Book: Chapter 6. What is verification? Traditionally, verification means proof of correctness automatic: model checking deductive:
Optimizing Join Enumeration in Transformation-based Query Optimizers ANIL SHANBHAG, S. SUDARSHAN IIT BOMBAY VLDB 2014
Probabilistic Planning (goal-oriented) Action Probabilistic Outcome Time 1 Time 2 Goal State 1 Action State Maximize Goal Achievement Dead End A1A2 I A1.
Game-theoretic approach to the simulation checking problem Peter Bulychev Vladimir Zakharov Lomonosov Moscow State University.
The Volcano/Cascades Query Optimization Framework
Efficient Reachability Analysis for Verification of Asynchronous Systems Nishant Sinha.
PSWLAB S PIN Search Algorithm from “THE SPIN MODEL CHECKER” by G Holzmann Presented by Hong,Shin 9 th Nov SPIN Search Algorithm.
1 Temporal Claims A temporal claim is defined in Promela by the syntax: never { … body … } never is a keyword, like proctype. The body is the same as for.
02/01/11CMPUT 671 Lecture 11 CMPUT 671 Hard Problems Winter 2002 Joseph Culberson Home Page.
Weizmann Institute Deciding equality formulas by small domain instantiations O. Shtrichman The Weizmann Institute Joint work with A.Pnueli, Y.Rodeh, M.Siegel.
Constraint Logic Programming Ryan Kinworthy. Overview Introduction Logic Programming LP as a constraint programming language Constraint Logic Programming.
28/6/05 ICFI05 1 A generic approach for the automatic verification of featured, parameterised systems Alice Miller and Muffy Calder University of Glasgow.
Algorithms and Problem Solving-1 Algorithms and Problem Solving.
Algorithms and Problem Solving. Learn about problem solving skills Explore the algorithmic approach for problem solving Learn about algorithm development.
Synthesis of Interface Specifications for Java Classes Rajeev Alur University of Pennsylvania Joint work with P. Cerny, G. Gupta, P. Madhusudan, W. Nam,
Summary of query compilers (Section16.8) Varun Gupta Department of Computer Science ID-216 CS 257.
ECE 667 Synthesis and Verification of Digital Systems
1 Formal Engineering of Reliable Software LASER 2004 school Tutorial, Lecture1 Natasha Sharygina Carnegie Mellon University.
Evaluating a Formal Methods Technique via Student Assessed Exercises Alastair Donaldson, Alice Miller University of Glasgow.
CS 290C: Formal Models for Web Software Lecture 4: Model Checking Navigation Models with Spin Instructor: Tevfik Bultan.
1 Reducibility. 2 Problem is reduced to problem If we can solve problem then we can solve problem.
Pablo A. Parrilo ETH Zürich Semialgebraic Relaxations and Semidefinite Programs Pablo A. Parrilo ETH Zürich control.ee.ethz.ch/~parrilo.
Model Checking and Related Techniques
CSE 589 Applied Algorithms Spring Colorability Branch and Bound.
Courtesy RK Brayton (UCB) and A Kuehlmann (Cadence) 1 Logic Synthesis Two-Level Minimization II.
Tractable Symmetry Breaking Using Restricted Search Trees Colva M. Roney-Dougal, Ian P. Gent, Tom Kelsey, Steve Linton Presented by: Shant Karakashian.
Mining Frequent Itemsets with Constraints Takeaki Uno Takeaki Uno National Institute of Informatics, JAPAN Nov/2005 FJWCP.
Parallel and Distributed Computing in Model Checking Diana DUBU (UVT) Dana PETCU (IeAT, UVT)
Daniel Kroening and Ofer Strichman 1 Decision Procedures in First Order Logic Decision Procedures for Equality Logic Range Allocation.
Scientific Computing By: Fatima Hallak To: Dr. Guy Tel-Zur.
Review Byron Gao. Overview Theory of computation: central areas: Automata, Computability, Complexity Computability: Is the problem solvable? –solvable.
Computer Science 101 Fast Searching and Sorting. Improving Efficiency We got a better best case by tweaking the selection sort and the bubble sort We.
CSC 413/513: Intro to Algorithms NP Completeness.
Week 10Complexity of Algorithms1 Hard Computational Problems Some computational problems are hard Despite a numerous attempts we do not know any efficient.
An Efficient Algorithm for Enumerating Pseudo Cliques Dec/18/2007 ISAAC, Sendai Takeaki Uno National Institute of Informatics & The Graduate University.
Inferring Synchronization under Limited Observability Martin Vechev, Eran Yahav, Greta Yorsh IBM T.J. Watson Research Center (work in progress)
CSCI 3160 Design and Analysis of Algorithms Tutorial 10 Chengyu Lin.
Today’s Agenda  Reminder: HW #1 Due next class  Quick Review  Input Space Partitioning Software Testing and Maintenance 1.
1 Checking Interaction Consistency in MARMOT Component Refinements Yunja Choi School of Electrical Engineering and Computer Science Kyungpook National.
NP-COMPLETE PROBLEMS. Admin  Two more assignments…  No office hours on tomorrow.
Computer Science 101 A Survey of Computer Science Timing Problems.
NP-Complete problems.
May University of Glasgow Generalising Feature Interactions in Muffy Calder, Alice Miller Dept. of Computing Science University of Glasgow.
/ PSWLAB S PIN Search Optimization from “THE SPIN MODEL CHECKER” by G. Holzmann Presented by Hong,Shin 23 th Nov SPIN Search.
Chapter 15 P, NP, and Cook’s Theorem. 2 Computability Theory n Establishes whether decision problems are (only) theoretically decidable, i.e., decides.
Young CS 331 D&A of Algo. NP-Completeness1 NP-Completeness Reference: Computers and Intractability: A Guide to the Theory of NP-Completeness by Garey and.
Faster Symmetry Discovery using Sparsity of Symmetries Paul T. Darga Karem A. Sakallah Igor L. Markov The University of Michigan.
CIS 842: Specification and Verification of Reactive Systems Lecture INTRO-Depth-Bounded: Depth-Bounded Depth-first Search Copyright 2004, Matt Dwyer, John.
Today’s Agenda  Quiz 4  Temporal Logic Formal Methods in Software Engineering1.
Algorithms and Problem Solving. Learn about problem solving skills Explore the algorithmic approach for problem solving Learn about algorithm development.
Symbolic Model Checking of Software Nishant Sinha with Edmund Clarke, Flavio Lerda, Michael Theobald Carnegie Mellon University.
Honors Track: Competitive Programming & Problem Solving Seminar Topics Kevin Verbeek.
Game Playing Why do AI researchers study game playing?
Algorithms and Problem Solving
Abstraction and Refinement for Large Scale Model Checking
Creativity in Algorithms
Dana Moshkovitz The Institute For Advanced Study
The University of Adelaide, School of Computer Science
Algorithms and Problem Solving
An explicit state model checker
A Refinement Calculus for Promela
Generic SBDD using Computational Group Theory
Algorithm Course Algorithms Lecture 3 Sorting Algorithm-1
Presentation transcript:

General Techniques for Symmetry Reduction in Model Checking Alastair Donaldson Alice Miller Department of Computing Science University of Glasgow

Model Checking System design or code Requirements Finite state model M Set of logical properties Model checker M |= φ ? for each property φ No Yes √ ? manual automatic

Model Written in High Level Language byte tok = 1; active [2] proctype user() { byte state = N; do :: (state == N) -> state = T :: (state == T) && (tok == _pid) -> state = C :: (state == C) -> state = N; if :: tok = 1 :: tok = 2 fi od }

Symmetry Reduction: Example N 1 N 2 tok=1 N 1 N 2 tok=2 N 1 T 2 tok=1 T 1 N 2 tok=2 T 1 N 2 tok=1 N 1 T 2 tok=2 T 1 T 2 tok=1 T 1 T 2 tok=2 C 1 N 2 tok=1 N 1 C 2 tok=2 C 1 T 2 tok=1 T 1 C 2 tok=2 N 1 N 2 tok=1 N 1 T 2 tok=1 T 1 N 2 tok=1 T 1 T 2 tok=1 C 1 N 2 tok=1 C 1 T 2 tok=1 State-graphReduced state-graph

Symmetry Reduction – Informally  Symmetry partitions state-space into equivalence classes  Knowledge of symmetry  search only 1 state per equivalence class  Need techniques for: Symmetry detection Efficient exploitation of symmetry  Ideally both should be fully automatic This talk

TopSPIN Promela source code G Symmetry group for state-space Symmetry reduction strategy for G, based on group structure Minimising set Enumerate Local search… pan.c sympan.c SymmExtractor Generate verifier using SPIN Use GAP to classify structure of G Adjust verifier to incorporate symmetry reduction strategy pan.exe M |= φ or counter example gcc execute sympan.exe gcc M G |= φ or counter example Based on approach used by SymmSpin (Bosnacki et. al 2002)

Model Checking With Symmetry  Suppose we have magic function, rep : S → S  Encounter state s Is rep(s) in reached? Yes: backtrack No: add rep(s) to reached & explore successors of rep(s) Standard approach: take rep(s) to be smallest state in equivalence class Represent state as tuple of local states, e.g. (A,A,B) Total ordering on states follows

Obvious Approach  Given s, consider σ(s) for all σ  G  Choose smallest σ(s) as rep(s)  If |G| = 10 this is fine  If |G| = 10! > 3,000,000 this is bad

The Orbit Problem  Constructive orbit problem (COP) – compute smallest state in equivalence class of s under G  NP-hard [Jha 1996]  However, for many classes of group, COP can be solved in polynomial time  The function rep can be approximate – representatives don’t have to be unique

Easy Groups: Small  N processes  |G| < N 2  Enumerate  Could use bound f(N) for some +ve valued polynomial f

Easy Groups: Fully Symmetric  Largest kind of groups  N processes, |S N |=N!  Compute representative by sorting state  Example: Local states A, B, C with A < B < C. 5 processes. s = (C,B,B,A,B) rep(s) = (A,B,B,B,C)  Sorting is easy! This can be generalised

Easy Groups: Disjoint Products  M+N processes  G = S {1,…,M}. S {M+1,…,M+N}  Sort both sections Suppose M = N = 5 s = (B,A,A,C,B|A,C,B,A,A) rep(s) = (A,A,B,B,C|A,A,A,B,C)  This generalises Based on Jha 1996

Easy Groups: Wreath Products  Example s = (A,B,A|B,C,B|C,A,A|A,A,A) (A,A,B|B,B,C|A,A,C|A,A,A) rep(s) = (A,A,A|A,A,B|A,A,C|B,B,C)  This generalises Based on Jha 1996

Classifying a Group G  Small groups / fully symmetric groups Easy to detect  Disjoint products: Construct equivalence relation on generators Factors of product generated by equivalence classes  Wreath products: Look at maximal block systems of G restricted to individual orbits  Classify G using a recursive algorithm

Local Search for Unclassifiable Groups orbit of s s G = t u          min  5d Hypercube |G|=3840 No reduction: 9.6 x 10 6 states, 2965 s Full reduction: 3907 states, 5241 s Local search: states, 946 s

Summary  Symmetry techniques aim to improve model checkers  Challenges: detecting & exploiting symmetries  Group structure can lead to efficient exploitation  Computational group theory can help find structure  Local search can be applied as an approximate strategy

References  A.F. Donaldson and A. Miller – Automatic Symmetry Detection for Model Checking Using Compuataional Group Theory (FM’05)  A.F. Donaldson and A. Miller – A Computational Group Theoretic Symmetry Reduction Package for the SPIN Model Checker (AMAST’06)  S. Jha – Symmetry and Induction in Model Checking (PhD Thesis 1996)