Classification Schemes to Aid in the Analysis of Real-Time Systems Paul Z. Kolano Trusted Systems Laboratories trustedsyslabs.com Richard.

Slides:



Advertisements
Similar presentations
Automated Theorem Proving Lecture 1. Program verification is undecidable! Given program P and specification S, does P satisfy S?
Advertisements

A Technique for Parallel Reachability Analysis of Java Programs Raghuraman R. Sridhar Iyer G. Sajith.
Translation-Based Compositional Reasoning for Software Systems Fei Xie and James C. Browne Robert P. Kurshan Cadence Design Systems.
Introducing Formal Methods, Module 1, Version 1.1, Oct., Formal Specification and Analytical Verification L 5.
Abstraction and Modular Reasoning for the Verification of Software Corina Pasareanu NASA Ames Research Center.
Reduction, abstraction, and atomicity: How much can we prove about concurrent programs using them? Serdar Tasiran Koç University Istanbul, Turkey Tayfun.
Automated Refinement Checking of Concurrent Systems Sudipta Kundu, Sorin Lerner, Rajesh Gupta Department of Computer Science and Engineering, University.
1 Dynamic Programming Week #4. 2 Introduction Dynamic Programming (DP) –refers to a collection of algorithms –has a high computational complexity –assumes.
1 Mechanical Verification of Timed Automata Myla Archer and Constance Heitmeyer Presented by Rasa Bonyadlou 24 October 2002.
6/14/991 Symbolic verification of systems with state machines David L. Dill Jeffrey Su Jens Skakkebaek Computer System Laboratory Stanford University.
Background information Formal verification methods based on theorem proving techniques and model­checking –to prove the absence of errors (in the formal.
1 Formal Methods in SE Qaisar Javaid Assistant Professor Lecture 05.
1 Simulator-Model Checker for Reactive Real-Time Abstract State Machines Anatol Slissenko University Paris 12 Pavel Vasilyev University Paris 12 University.
An Integration of Program Analysis and Automated Theorem Proving Bill J. Ellis & Andrew Ireland School of Mathematical & Computer Sciences Heriot-Watt.
Introduction to Computability Theory
STARI: A Case Study in Compositional and Hierarchical Timing Verification Serdar Tasiran, Prof. Robert K. Brayton Department of Electrical Engineering.
VIDE Integrated Environment for Development and Verification of Programs.
Scheduling for Embedded Real-Time Systems Amit Mahajan and Haibo.
1 Evaluation of OCL for Large-Scale Modelling A Different View of the Mondex Smart Card Application Emine G. Aydal, Richard F. Paige, Jim Woodcock University.
Discrete-Event Simulation: A First Course Steve Park and Larry Leemis College of William and Mary.
Chapter 2: Algorithm Discovery and Design
Verification of Hierarchical Cache Coherence Protocols for Future Processors Student: Xiaofang Chen Advisor: Ganesh Gopalakrishnan.
Categories of Aspects Shmuel Katz Computer Science Department The Technion Haifa, Israel.
1 Ivan Lanese Computer Science Department University of Bologna Italy Concurrent and located synchronizations in π-calculus.
THE OBJECT-ORIENTED DESIGN WORKFLOW Statechart Diagrams.
Operational Semantics Semantics with Applications Chapter 2 H. Nielson and F. Nielson
Formal verification Marco A. Peña Universitat Politècnica de Catalunya.
Design Synopsys System Verilog API Donations to Accellera João Geada.
272: Software Engineering Fall 2012 Instructor: Tevfik Bultan Lecture 4: SMT-based Bounded Model Checking of Concurrent Software.
Thread-modular Abstraction Refinement Thomas A. Henzinger, et al. CAV 2003 Seonggun Kim KAIST CS750b.
Cheng/Dillon-Software Engineering: Formal Methods Model Checking.
Timed UML State Machines Ognyana Hristova Tutor: Priv.-Doz. Dr. Thomas Noll June, 2007.
(C) 2009 J. M. Garrido1 Object Oriented Simulation with Java.
Chapter 2: Algorithm Discovery and Design Invitation to Computer Science, C++ Version, Third Edition.
Unit III : Introduction To Data Structures and Analysis Of Algorithm 10/8/ Objective : 1.To understand primitive storage structures and types 2.To.
Bug Localization with Machine Learning Techniques Wujie Zheng
B. Fernández, D. Darvas, E. Blanco Formal methods appliedto PLC code verification Automation seminar CERN – IFAC (CEA) 02/06/2014.
Lecture 2 Foundations and Definitions Processes/Threads.
Java Threads 11 Threading and Concurrent Programming in Java Introduction and Definitions D.W. Denbo Introduction and Definitions D.W. Denbo.
CS6133 Software Specification and Verification
Formal Verification Lecture 9. Formal Verification Formal verification relies on Descriptions of the properties or requirements Descriptions of systems.
Lyra – A service-oriented and component-based method for the development of communicating systems (by Sari Leppänen, Nokia/NRC) Traditionally, the design,
02/04/2008 A Concrete Syntax for UML 2.1 Action Semantics Using +CAL 13th IEEE International Conference on Engineering of Complex Computer Systems – ICECCS.
Object Oriented Discrete-Event Simulation CS4730 Fall 2010 Jose M. Garrido Department of Computer Science and Information Systems Kennesaw State University.
More on Efficiency Issues. Greatest Common Divisor given two numbers n and m find their greatest common divisor possible approach –find the common primes.
1 Model Checking of Robotic Control Systems Presenting: Sebastian Scherer Authors: Sebastian Scherer, Flavio Lerda, and Edmund M. Clarke.
On Coding for Real-Time Streaming under Packet Erasures Derek Leong *#, Asma Qureshi *, and Tracey Ho * * California Institute of Technology, Pasadena,
Introduction to Operating Systems and Concurrency.
CIS 842: Specification and Verification of Reactive Systems Lecture INTRO-Examples: Simple BIR-Lite Examples Copyright 2004, Matt Dwyer, John Hatcliff,
Motivation  Parallel programming is difficult  Culprit: Non-determinism Interleaving of parallel threads But required to harness parallelism  Sequential.
Predicate Abstraction. Abstract state space exploration Method: (1) start in the abstract initial state (2) use to compute reachable states (invariants)
From Hoare Logic to Matching Logic Reachability Grigore Rosu and Andrei Stefanescu University of Illinois, USA.
Constraints Assisted Modeling and Validation Presented in CS294-5 (Spring 2007) Thomas Huining Feng Based on: [1]Constraints Assisted Modeling and Validation.
Plan 1.Introduction a)What is a Program Fault? b)Deterministic/Non-Deterministic Programs 2.A Refinement Calculus 3.Relative Correctness for Non Deterministic.
Theory-Aided Model Checking of Concurrent Transition Systems Guy Katz, Clark Barrett, David Harel New York University Weizmann Institute of Science.
Formal Verification. Background Information Formal verification methods based on theorem proving techniques and model­checking –To prove the absence of.
Automated Formal Verification of PLC (Programmable Logic Controller) Programs
/ PSWLAB Thread Modular Model Checking by Cormac Flanagan and Shaz Qadeer (published in Spin’03) Hong,Shin Thread Modular Model.
High Performance Embedded Computing © 2007 Elsevier Lecture 4: Models of Computation Embedded Computing Systems Mikko Lipasti, adapted from M. Schulte.
Undergraduate course on Real-time Systems Linköping University TDDD07 Real-time Systems Lecture 2: Scheduling II Simin Nadjm-Tehrani Real-time Systems.
Chapter 2: Algorithm Discovery and Design Invitation to Computer Science.
Agenda  Quick Review  Finish Introduction  Java Threads.
Week#3 Software Quality Engineering.
Credible Compilation With Pointers Martin Rinard and Darko Marinov Laboratory for Computer Science Massachusetts Institute of Technology.
CSCI 2670 Introduction to Theory of Computing November 15, 2005.
Chapter 8: Concurrency Control on Relational Databases
Matching Logic An Alternative to Hoare/Floyd Logic
(One-Path) Reachability Logic
IS 2935: Developing Secure Systems
Foundations and Definitions
Presentation transcript:

Classification Schemes to Aid in the Analysis of Real-Time Systems Paul Z. Kolano Trusted Systems Laboratories trustedsyslabs.com Richard A. Kemmerer University of California, Santa Barbara

Outline of Presentation Introduction Brief ASTRAL overview Property classifications Process classifications Transition classifications Conclusion

Real-Time Systems Untimed + Concurrency + Asynchrony + Time + Nondeterminism + Reactivity = Difficult to analyze

Proof Assistance Is Needed Model checkers Automatically check state space for violations Theorem provers Keep reasoning sound, finish off proof details Need simplifications and manual abstractions Need human guidance and intuition Systematic analysis guidance How analysis can be performed based on previous experience How each approach can be used most effectively How results from different approaches can be combined

How Can Analysis Be Systematized? Identify distinct proof patterns Identify distinguishing features of system specifications that result in each pattern Divide and conquer Separate specifications with different patterns Separate individual proofs into simpler pieces

Testbed Systems Bakery algorithm Cruise control Elevator control system Olympic boxing scoring system Phone system Production cell Railroad crossing Stoplight control system Small/Large Simple/Complex Open/Closed Deterministic/ Nondeterministic Assumptions not needed/ Assumptions needed

Classification Schemes Distinct proof styles Statically recognizable ASTRAL classifications Property classifications Process classifications Transition classifications

Outline of Presentation Introduction Brief ASTRAL overview Property classifications Process classifications Transition classifications Conclusion

Railroad Crossing

ASTRAL Specification One or more process type specifications Each defines an abstract state machine A global specification Defines types, constants, etc. shared among process types Defines number of statically generated instances of each process type in the system Example: Railroad Crossing specification Process types Process instances Gate 1 Gate instance Sensor N_Tracks Sensor instances

Process Type Specification Types Variables Define state of process Initialization Defines initial values Transitions Define changes to variable values TYPE gate_position: (raised, raising, lowered, lowering) VARIABLE position: gate_position INITIAL position = raised TRANSITION lower ENTRY [TIME: lower_dur] ~ ( position = lowering | position = lowered ) & EXISTS s: sensor_id (s.train_in_R) EXIT position = lowering

Process Interactions

Specification of Properties INVARIANT Change(train_in_R, now) & ~train_in_R  FORALL t: time ( now - ((dist_R_to_I + dist_I_to_out) / max_speed - response_time)  t & t < now  past(train_in_R, t)) ENVIRONMENT Call(enter_R, now) & EXISTS t: time ( 0  t & t  now & Call 2 (enter_R, t))  Call(enter_R) - Call 2 (enter_R) > (dist_R_to_I + dist_I_to_out) / min_speed Requirements Invariants Schedules Assumptions Environment Imported variable

Outline of Presentation Introduction Brief ASTRAL overview Property classifications Process classifications Transition classifications Conclusion

Property Classifications Untimed properties Timed liveness properties Forward Backward Timed safety properties Forward Backward

Context and Requirement Times General form of a property context  requirement Context times are times referenced in the timed operator expressions of the context Requirement times are times referenced in the timed operator expressions of the requirement

Example of Context and Requirement Times FORALL t: time, s: sensor_id ( Change(s.train_in_R, now - dist_R_to_I / max_speed + response_time) & past(s.train_in_R, now - dist_R_to_I / max_speed + response_time)  EXISTS t: time ( now - dist_R_to_I / max_speed + response_time  t & t  now & past(position, t) = lowered)) Context times = {now - dist_R_to_I / max_speed + response_time} Requirement times = {t}

Untimed Properties Context times and requirement times can only be the current time With only local state variables FORALL d: direction ( Circle(d) = green  Arrow(opp(d)) = red) With timed operators/imported variables Change(number, now) & Number = 0  ~In_critical

Untimed Properties With Only Local State Variables State variables only change when transitions end These properties hold if the exit assertion of each transition preserves the property maintaining_speed  cruise_on TRANSITION maintain_speed ENTRY [TIME: input_dur] cruise_on & ~maintaining_speed EXIT cruise_throttle = throttle & desired_speed = speedometer.speed & maintaining_speed

Forward vs. Backward Forward EXISTS ct: context time FORALL rt: requirement time ct  rt Backward EXISTS rt: requirement time FORALL ct: context time rt  ct FORALL t: time, s: sensor_id ( Change(s.train_in_R, now - dist_R_to_I / max_speed + response_time) & past(s.train_in_R, now - dist_R_to_I / max_speed + response_time)  EXISTS t: time ( now - dist_R_to_I / max_speed + response_time  t & t  now & past(position, t) = lowered)) Change(train_in_R, now) & ~train_in_R  FORALL t: time ( now - ((dist_R_to_I + dist_I_to_out) / max_speed - response_time)  t & t < now  past(train_in_R, t))

Forward vs. Backward The execution tree of a process

Safety vs. Liveness Safety properties Must hold at all times in an interval Liveness properties Must hold at least once in an interval Can abstract away details of execution Must derive exact executions

Safety Properties Change(train_in_R, now) & ~train_in_R  FORALL t: time ( now - ((dist_R_to_I + dist_I_to_out) / max_speed - response_time)  t & t < now  past(train_in_R, t)) TRANSITION exit_I ENTRY [TIME: exit_dur] train_in_R & now - Start(enter_R)  (dist_R_to_I + dist_I_to_out) / min_speed - exit_dur EXIT ~train_in_R

Liveness Properties FORALL t: time, s: sensor_id ( Change(s.train_in_R, now - dist_R_to_I / max_speed + response_time) & past(s.train_in_R, now - dist_R_to_I / max_speed + response_time)  EXISTS t: time ( now - dist_R_to_I / max_speed + response_time  t & t  now & past(position, t) = lowered))

Property Classifications of Testbed Systems

Outline of Presentation Introduction Brief ASTRAL overview Property classifications Process classifications Transition classifications Conclusion

Process Classifications Multi-threaded process Iterative single-threaded process Simple single-threaded process

Multi-Threaded Process Multiple independent threads interleaved on a single process

Liveness Properties in a Multi-Threaded Process Must take scheduling policy into account Example: fixed priority scheduling

Iterative Single-Threaded Process Cyclic behavior with stored iteration count

Liveness Properties in an Iterative Single-Threaded Process Properties may need to be proved between arbitrary values of the iteration count

Simple Single-Threaded Process May have cyclic behavior, but iteration count not stored Properties usually need to be proved over only a single full cycle

Process Classifications of Testbed Systems Multi-threaded processes (2/25) Central_Control (phone system) Controller (stoplight control system) Iterative single-threaded processes (4/25) Elevator (elevator control system) Proc (bakery algorithm) Timer and Tabulate (Olympic boxing system) Simple single-threaded processes (19/25)

Outline of Presentation Introduction Brief ASTRAL overview Property classifications Process classifications Transition classifications Conclusion

Transition Classifications Transition enablement Local state (L) External environment (E) Imported state (O) Current time (T) Eight classifications based on these factors L, E, O, T, EO, ET, OT, EOT TRANSITION lower ENTRY [TIME: lower_dur] ~ ( position = lowering | position = lowered ) & EXISTS s: sensor_id (s.train_in_R) EXIT position = lowering

Determining Transition Delays e.g., L transitions Local state only changes when transitions end Must immediately follow previous transition e.g., T transitions Delayed from some local state/event e.g., now – End(trans1)  delay1 Other transition types Examine relevant clauses

Transition Classifications of Testbed Systems SystemLEOTEOETOTEOTTotal Bakery Algorithm Cruise Control Elevator Olympic Boxing Phone Production Cell Railroad Crossing Stoplight Total

Outline of Presentation Introduction Brief ASTRAL overview Property classifications Process classifications Transition classifications Conclusion

Conclusions Three classification schemes were developed from existing specifications Property classifications Process classifications Transition classifications Statically recognizable Each aids in the proof process

Future Work Examine more real-time systems Are there additional classification schemes that are useful? Examine other specification languages Are the existing classification schemes applicable to many specification languages?

The End For complete details, see dissertation...