Transaction Ordering Verification using Trace Inclusion Refinement Mike Jones 11 January 2000.

Slides:



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

Functional Decompositions for Hardware Verification With a few speculations on formal methods for embedded systems Ken McMillan.
1 Data Link Protocols By Erik Reeber. 2 Goals Use SPIN to model-check successively more complex protocols Using the protocols in Tannenbaums 3 rd Edition.
Auto-Generation of Test Cases for Infinite States Reactive Systems Based on Symbolic Execution and Formula Rewriting Donghuo Chen School of Computer Science.
Impossibility of Distributed Consensus with One Faulty Process
Translation-Based Compositional Reasoning for Software Systems Fei Xie and James C. Browne Robert P. Kurshan Cadence Design Systems.
Certified Typechecking in Foundational Certified Code Systems Susmit Sarkar Carnegie Mellon University.
Introducing Formal Methods, Module 1, Version 1.1, Oct., Formal Specification and Analytical Verification L 5.
Automatic Verification Book: Chapter 6. What is verification? Traditionally, verification means proof of correctness automatic: model checking deductive:
Abstraction and Modular Reasoning for the Verification of Software Corina Pasareanu NASA Ames Research Center.
Foundational Certified Code in a Metalogical Framework Karl Crary and Susmit Sarkar Carnegie Mellon University.
PROTOCOL VERIFICATION & PROTOCOL VALIDATION. Protocol Verification Communication Protocols should be checked for correctness, robustness and performance,
UPPAAL Introduction Chien-Liang Chen.
Timed Automata.
Transaction Based Modeling and Verification of Hardware Protocols Xiaofang Chen, Steven M. German and Ganesh Gopalakrishnan Supported in part by Intel.
1 COMP 382: Reasoning about algorithms Unit 9: Undecidability [Slides adapted from Amos Israeli’s]
Distributed Computing 8. Impossibility of consensus Shmuel Zaks ©
ISBN Chapter 3 Describing Syntax and Semantics.
Software Reliability CIS 640 Adapted from the lecture notes by Doron Pelel (
Demonstration Of SPIN By Mitra Purandare
CIS 540 Principles of Embedded Computation Spring Instructor: Rajeev Alur
Formal Methods in Software Engineering Credit Hours: 3+0 By: Qaisar Javaid Assistant Professor Formal Methods in Software Engineering1.
1 Introduction to Computability Theory Lecture15: Reductions Prof. Amos Israeli.
1 Introduction to Computability Theory Lecture12: Reductions Prof. Amos Israeli.
CPSC 411, Fall 2008: Set 12 1 CPSC 411 Design and Analysis of Algorithms Set 12: Undecidability Prof. Jennifer Welch Fall 2008.
28/6/05 ICFI05 1 A generic approach for the automatic verification of featured, parameterised systems Alice Miller and Muffy Calder University of Glasgow.
Synergy: A New Algorithm for Property Checking
Lecture 4&5: Model Checking: A quick introduction Professor Aditya Ghose Director, Decision Systems Lab School of IT and Computer Science University of.
ECE Synthesis & Verification1 ECE 667 Spring 2011 Synthesis and Verification of Digital Systems Verification Introduction.
Verification of Hierarchical Cache Coherence Protocols for Future Processors Student: Xiaofang Chen Advisor: Ganesh Gopalakrishnan.
Transaction Ordering Verification using Trace Inclusion Refinement Mike Jones 11 January 2000.
Describing Syntax and Semantics
EE694v-Verification-Lect5-1- Lecture 5 - Verification Tools Automation improves the efficiency and reliability of the verification process Some tools,
Transaction Based Modeling and Verification of Hardware Protocols Xiaofang Chen, Steven M. German and Ganesh Gopalakrishnan Supported in part by SRC Contract.
Formal verification Marco A. Peña Universitat Politècnica de Catalunya.
Halting Problem. Background - Halting Problem Common error: Program goes into an infinite loop. Wouldn’t it be nice to have a tool that would warn us.
1 PCI transaction ordering verification using trace inclusion refinement Mike Jones UV Meeting October 4, 1999.
Cheng/Dillon-Software Engineering: Formal Methods Model Checking.
Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.
Proof Carrying Code Zhiwei Lin. Outline Proof-Carrying Code The Design and Implementation of a Certifying Compiler A Proof – Carrying Code Architecture.
1 New Development Techniques: New Challenges for Verification and Validation Mats Heimdahl Critical Systems Research Group Department of Computer Science.
1 The CeNTIE project is supported by the Australian Government through the Advanced Networks Program of the Department of Communications, Information Technology.
Formal Verification Lecture 9. Formal Verification Formal verification relies on Descriptions of the properties or requirements Descriptions of systems.
Syntax and Semantics CIS 331 Syntax: the form or structure of the expressions, statements, and program units. Semantics: the meaning of the expressions,
Network Protocols Network Systems Security Mort Anvari.
Verification & Validation By: Amir Masoud Gharehbaghi
CSCI1600: Embedded and Real Time Software Lecture 28: Verification I Steven Reiss, Fall 2015.
Understanding ADTs CSE 331 University of Washington.
Static Techniques for V&V. Hierarchy of V&V techniques Static Analysis V&V Dynamic Techniques Model Checking Simulation Symbolic Execution Testing Informal.
Fault tolerance and related issues in distributed computing Shmuel Zaks GSSI - Feb
CIS 540 Principles of Embedded Computation Spring Instructor: Rajeev Alur
Complexity 24-1 Complexity Andrei Bulatov Interactive Proofs.
Types and Programming Languages Lecture 3 Simon Gay Department of Computing Science University of Glasgow 2006/07.
CSC3315 (Spring 2009)1 CSC 3315 Languages & Compilers Hamid Harroud School of Science and Engineering, Akhawayn University
1 Critical Section Problem CIS 450 Winter 2003 Professor Jinhua Guo.
Writing, Verifying and Exploiting Formal Specifications for Hardware Designs Chapter 3: Verifying a Specification Presenter: Scott Crosby.
Abstraction and Abstract Interpretation. Abstraction (a simplified view) Abstraction is an effective tool in verification Given a transition system, we.
Formal verification of distance vector routing protocols.
Formal Methods: Model Checkers and Theorem Provers
CSE-321 Programming Languages Simply Typed -Calculus
Michael D. Jones, Ganesh Gopalakrishnan
LIMITS OF ALGORITHMIC COMPUTATION
Aspect Validation: Connecting Aspects and Formal Methods
Property Directed Reachability with Word-Level Abstraction
IS 2935: Developing Secure Systems
Automated Extraction of Inductive Invariants to Aid Model Checking
Halting Problem.
Test Case Test case Describes an input Description and an expected output Description. Test case ID Section 1: Before execution Section 2: After execution.
Predicate Abstraction
Program correctness Model-checking CTL
Presentation transcript:

Transaction Ordering Verification using Trace Inclusion Refinement Mike Jones 11 January 2000

2 Case Study Check the producer consumer property for PCI 2.1 protocol. Which formal methods are best suited for reasoning about large protocols over unbounded branching networks? Resulting tools apply to designing, not implementing, a protocol over unbounded branching networks.

3 Formal methods (in 1 slide) Formal = truth is based on form, not meaning. Syntax, not semantics, matters. Theorem proving –expressive, interactive, machine-checked Model checking –unexpressive, automatic, complexity Hybrid techniques Intel, HP, Compaq, Microsoft, AMD, SRI, Lucent, VSIA...

4 Why PCI? It works. Why verify it? Published standard violated prod/cons. Stationary target. Beyond current formal techniques.

5 How PCI works AgentBridge Bus p d d c Delayed Posted completion

6 Posted transactions Posted transaction, P, from A to B. A puts p on “the rest of the network” and forgets about it. B receives P and that’s it. A B p The Rest of the network

7 Posted transactions Pretend there are 2 bridges between A and B With the other transaction shown. Here’s how P gets from A to B... A B p cdp’

8 Posted transactions P goes to bridge 1. P is now complete at A. P can pass delayed transaction d A B p cdp’

9 Posted transactions Next, P completes to bridge 2. A B p cdp’

10 Posted transactions P is now complete at bridge 1. P can pass the completion trans. C. P can not pass the other posted trans. A B p cdp’

11 Posted transactions P waits until P’ completes on bridge 2 A B p cdp’

12 Posted transactions Pretend that P’ went to another bridge (not shown). P can now complete to destination B. A B p cd

13 Posted transactions No acknowledgement is sent to A. P is now complete at B. A B p cd

14 Delayed transactions Delayed trans., d, from A to B. A puts d on “the rest of the network” and waits for a completion. B receives d and sends a completion,c. A B d The Rest of the network

15 Delayed transactions 2 bridges between A and B Other transactions as shown. d tries to latch to bridge 1. d is now committed (called d’). A B d’ cdp’

16 Delayed transactions Eventually, d’ latches to bridge 1. bridge 1 has an uncommitted copy of d d can pass the other d entry already in bridge 1. A B d’ cdp’ d

17 Delayed transactions d can attempt to latch to bridge 2. d will then be committed at bridge 1. A B d’ cdp’ d

18 Delayed transactions Eventually, d’ latches to bridge 2. A B d’ cdp’ d’

19 Delayed transactions d can pass completion entry c. A B d’ cdp’ d’d

20 Delayed transactions But, uncommitted d entries can be dropped at any time... A B d’ cdp’ d’d

21 Delayed transactions bridge 1 has to resend d’ to bridge 2 d’ can not be deleted A B d’ cdp’ d’

22 Delayed transactions d can be dropped again... pretend it passes C again. d can not pass posted transactions. d waits till p’ completes. A B d’ cdp’ d’d

23 Delayed transactions d commits then latches to agent B. B creates a completion entry C. A B d’ cd d

24 Delayed transactions d’ in bridge 2 can complete with the completion in B. d’ will be deleted from bridge 2. c will move into into bridge 2. A B d’ cd c

25 Delayed transactions d is now complete at bridge 2. d’ in bridge 1 can complete with c in bridge 2. c can be deleted too... A B d’ cd c

26 Delayed transactions d is now complete at bridge 1. finally, d’ in agent A completes with c in bridge 1. A B d’ cd c

27 Delayed transactions d is now complete at A. no more actions! A B cd d’ c

28 Reordering and deletion P can pass anything except P. D and C can pass either D or C. uncommitted D can be dropped. oldest C in a queue can be dropped. P and committed D never dropped.

29 Producer/Consumer property if a producer agent writes a data item and the producer sets a flag and if the consumer reads the flag then the consumer will read the new data item.

30 Producer/Consumer for PCI... p c d f...for all networks and all executions.

31 Solution Carefully reduce the problem Check the reduced problem Generalize results

32 Related work Other PCI work. –liveness [Corella,97] –state machine specifications [Clarke,99] –U of Utah [Mokkedem et al,00] Unbounded branching networks. –predicate transformers[Kesten,97] –predicate abstraction[Das,99] –Combined method [Abdulla,99]

33 Careful reduction Reduce arbitrary PCI networks to N networks. Reduce infinite state to finite states. Show that PCI is a trace inclusion refinement of the reduced protocol.

34 Structural Reduction

35 Structural Reduction

36 Structural Reduction pd c f pc d f pd c f

37 Unrelated paths and agents... p c d f p c d f 

38 State reduction PCI networks have an infinite # of states. Ignore certain transactions while preserving the PC property.

39 Unrelated Transactions p... fwdwdwc cdwp d’cp pc pdd dp dwc dw fw cdw  p

40 Trace Inclusion Refinement For every trace in the concrete protocol.

41 Trace Inclusion Refinement For every trace in the concrete protocol. There exists a trace in the reduced protocol...

42 Trace Inclusion Refinement For every trace in the concrete protocol. There exists a trace in the reduced protocol... Such that the reduction of each concrete state is equal to the corresponding abstract state.

43...Applied to PCI Write a set of rules inductively defining the reachable states in PCI and reduced model.

44 Check reduced model Used SML and murphi model checker. Rules based input languages 3,176 states checked in 67 seconds. Property was satisfied.

45 Changing the model A different protocol –PCI without local master IDs –About 1/2 a day of effort –Plausible violation found in under 10 minutes A different property –When are two transactions received in order? –Useful for an on-chip bus being considered for SOC –1/2 an hour additional effort

46 Conclusions A combination of rule-based notation, theorem proving and model checking works. Easy to modify both the protocol and the property being checked.

47 Future work Automate the refinement proof. Tools for deriving reduced protocols for mutations of protocols. Anyone have a protocol over an unbounded network they need studied?

48

49 Outline Lay the groundwork Overview PCI and the property Our solution What makes our solution so good Discussion and conclusions

50 Why Formal Methods? simulation impossible: infinite states. Does not guaruntee correctness. Forced to identify assumptions. Capitol critical applications.

51 Structural Reduction Reduce any instance of PC to one of 3 abstract instances. Allows us to get complete structural coverage by checking 3 networks. Supported by a machine-checked proof. pd c f pc d f pd c f

52 Producer/Consumer for PCI Producer writes a data value and sets a flag. Consumer reads the flag then reads the data Assuming –no intervening writes –flag gets written before it gets read Then the consumer gets the new data value. Check this for ALL executions in ALL networks

53 What makes this problem hard All networks and all executions. Reasoning about PCI networks in general, using induction, is hard. Reasoning about individual PCI networks equals inefficient simulation.

54 Trace Inclusion Refinement