Real-Time Model Checking on Secondary Storage Stefan Edelkamp and Shahid Jabbar Chair for Programming Systems and Compiler Construction Computer Science.

Slides:



Advertisements
Similar presentations
Chapter 6: Memory Management
Advertisements

Equality Join R X R.A=S.B S : : Relation R M PagesN Pages Relation S Pr records per page Ps records per page.
PROBLEM SOLVING AND SEARCH
EDA (CS286.5b) Day 10 Scheduling (Intro Branch-and-Bound)
Timed Automata.
Accelerating External Search with Bitstate Hashing Stefan Edelkamp Shahid Jabbar Computer Science Department University of Dortmund, Dortmund, Germany.
Constraint Optimization Presentation by Nathan Stender Chapter 13 of Constraint Processing by Rina Dechter 3/25/20131Constraint Optimization.
Branch & Bound Algorithms
CPSC 322, Lecture 5Slide 1 Uninformed Search Computer Science cpsc322, Lecture 5 (Textbook Chpt 3.4) January, 14, 2009.
Biointelligence Lab School of Computer Sci. & Eng. Seoul National University Artificial Intelligence Chapter 8 Uninformed Search.
Chapter 7 Memory Management Operating Systems: Internals and Design Principles, 6/E William Stallings Dave Bremer Otago Polytechnic, N.Z. ©2009, Prentice.
1 Chapter 10 Query Processing: The Basics. 2 External Sorting Sorting is used in implementing many relational operations Problem: –Relations are typically.
1 Overview of Storage and Indexing Chapter 8 (part 1)
FALL 2006CENG 351 Data Management and File Structures1 External Sorting.
CS 4432lecture #31 CS4432: Database Systems II Lecture #3 Professor Elke A. Rundensteiner.
1 External Sorting Chapter Why Sort?  A classic problem in computer science!  Data requested in sorted order  e.g., find students in increasing.
Computer Organization and Architecture
External Memory Algorithms Kamesh Munagala. External Memory Model Aggrawal and Vitter, 1988.
1 External Sorting for Query Processing Yanlei Diao UMass Amherst Feb 27, 2007 Slides Courtesy of R. Ramakrishnan and J. Gehrke.
1 Query Processing: The Basics Chapter Topics How does DBMS compute the result of a SQL queries? The most often executed operations: –Sort –Projection,
Linear Systems The definition of a linear equation given in Chapter 1 can be extended to more variables; any equation of the form for real numbers.
Chapter 3 Memory Management: Virtual Memory
Chapter 13 Query Processing Melissa Jamili CS 157B November 11, 2004.
Automated Whitebox Fuzz Testing (NDSS 2008) Presented by: Edmund Warner University of Central Florida April 7, 2011 David Molnar UC Berkeley
Agenda Introduction Overview of White-box testing Basis path testing
Memory Management. Roadmap Basic requirements of Memory Management Memory Partitioning Basic blocks of memory management –Paging –Segmentation.
Cost-Optimal Symbolic Pattern Database Planning with State Trajectory and Preference Constraints Stefan Edelkamp University of Dortmund.
Computer Science CPSC 322 Lecture 9 (Ch , 3.7.6) Slide 1.
1 Overview of Storage and Indexing Chapter 8 (part 1)
1 Virtual Memory Chapter 9. 2 Resident Set Size n Fixed-allocation policy u Allocates a fixed number of frames that remains constant over time F The number.
Design of a High-Throughput Low-Power IS95 Viterbi Decoder Xun Liu Marios C. Papaefthymiou Advanced Computer Architecture Laboratory Electrical Engineering.
Lecture 3: Uninformed Search
Cost-Optimal Planning with Constraints and Preferences in Large State Spaces Stefan Edelkamp, Shahid Jabbar, Mohammed Nazih University of Dortmund.
1 Outline:  Optimization of Timed Systems  TA-Modeling of Scheduling Tasks  Transformation of TA into Mixed-Integer Programs  Tree Search for TA using.
1 Memory Management Chapter 7. 2 Memory Management Subdividing memory to accommodate multiple processes Memory needs to be allocated to ensure a reasonable.
Parallel External Directed Model Checking with Linear I/O Shahid Jabbar Stefan Edelkamp Computer Science Department University of Dortmund, Dortmund, Germany.
Computer Science CPSC 322 Lecture 6 Iterative Deepening and Search with Costs (Ch: 3.7.3, 3.5.3)
Presentation Template KwangSoo Yang Florida Atlantic University College of Engineering & Computer Science.
External A* Stefan Edelkamp, Shahid Jabbar (ich) University of Dortmund, Germany and Stefan Schrödl (DaimlerChrysler, CA)
External Memory Value Iteration Stefan Edelkamp, Shahid Jabbar Chair for Programming Systems, University of Dortmund, Germany Blai Bonet Departamento de.
Scheduling Lacquer Productions with Uppaal AXXOM case study of the Ametist project Angelika Mader Distributed and Embedded Systems Group, University of.
I/O Efficient Directed Model Checking Shahid Jabbar and Stefan Edelkamp, Computer Science Department University of Dortmund, Germany.
Query Execution. Where are we? File organizations: sorted, hashed, heaps. Indexes: hash index, B+-tree Indexes can be clustered or not. Data can be stored.
Page Buffering, I. Pages to be replaced are kept in main memory for a while to guard against poorly performing replacement algorithms such as FIFO Two.
Hash Tables and Query Execution March 1st, Hash Tables Secondary storage hash tables are much like main memory ones Recall basics: –There are n.
Fahiem Bacchus © 2005 University of Toronto 1 CSC384: Intro to Artificial Intelligence Search II ● Announcements.
3.5 Informed (Heuristic) Searches This section show how an informed search strategy can find solution more efficiently than uninformed strategy. Best-first.
Solving problems by searching A I C h a p t e r 3.
CPSC 322, Lecture 5Slide 1 Uninformed Search Computer Science cpsc322, Lecture 5 (Textbook Chpt 3.5) Sept, 13, 2013.
Large Scale External Directed Liveness Checking Stefan Edelkamp Shahid Jabbar Computer Science Department University of Dortmund, Dortmund, Germany.
Chapter 10 The Basics of Query Processing. Copyright © 2005 Pearson Addison-Wesley. All rights reserved External Sorting Sorting is used in implementing.
Biointelligence Lab School of Computer Sci. & Eng. Seoul National University Artificial Intelligence Chapter 8 Uninformed Search.
Memory management The main purpose of a computer system is to execute programs. These programs, together with the data they access, must be in main memory.
Wolfgang Runte Slide University of Osnabrueck, Software Engineering Research Group Wolfgang Runte Software Engineering Research Group Institute.
Lecture 3: Uninformed Search
Chapter 7 Memory Management
Uniformed Search (cont.) Computer Science cpsc322, Lecture 6
Chapter 2 Memory and process management
Database Management System
Chapter 12: Query Processing
Artificial Intelligence (CS 370D)
On Using Linearly Priced Timed Automata for Flow Analysis
Searching for Solutions
Lecture 2- Query Processing (continued)
Algorithms for Budget-Constrained Survivable Topology Design
Artificial Intelligence Chapter 8 Uninformed Search
CENG 351 Data Management and File Structures
CMSC 471 Fall 2011 Class #4 Tue 9/13/11 Uninformed Search
CS137: Electronic Design Automation
Presentation transcript:

Real-Time Model Checking on Secondary Storage Stefan Edelkamp and Shahid Jabbar Chair for Programming Systems and Compiler Construction Computer Science Department University of Dortmund, Dortmund, Germany

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 2 Real-Time Model Checking Model checking of real time critical systems.  Example: A rail-road crossing that has to follow strict time constraints. Systems are modeled by Timed-Automata  Extension of ordinary automata with clocks and constraints. s1 s2 s3 0 ≤ y ≤ 4 y ≤ 4 x ←0 y ≤ 4 Constraints Reset x and y are real-time clocks

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 3 Timed Automata A state in timed automata is a pair (l, u), where  l is the current location/state in the automata  u:C  IR is the Clock valuation function. Two types of Transitions:  Delay Transition: (l,u)  (l, u+d) that increases the values of all clocks by a positive real d.  Edge Transition: (l,u)  (l’, u’) that changes the location to l’. u’ is obtained from u by executing the reset statements on the edges. Only possible if the constraints on the edge are satisfied by the clocks. s1 s2 s3 0 ≤ y ≤ 4 y ≤ 4 x ←0 y ≤ 4 Constraints Reset x and y are real-time clocks

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 4 Priced Timed Automata Timed Automata extended with cost variables. Each transition can have a cost for taking it. Each location/state can have a cost for staying at it. Used in Scheduling – also in this paper. s1 s2 s3 0 ≤ y ≤ 4 y ≤ 4 x ←0 y ≤ 4 Constraints Reset x and y are real-time clocks c = 4 c = 2 c = c + 1 c = c + 4 Cost per unit time for staying at s1 Cost for taking the transition

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 5 Cost-optimal reachibility using Priced Timed Automata (UPPAAL-CORA) UPPAAL-CORA uses admissible but inconsistent heuristics as guidance. the first solution found is not optimal. But can be taken as an upper bound to prune the non-promising states – branch-and-bound. costcost Search frontier goal Pruning value

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 6 Problems Since clocks are real-values variables   infinite state spaces. Classical approach for proving decidability is to divide the state space into regions. In practice, tools like KRONOS and UPPAAL use a Zone-based representation – a symbolic representation for sets of states. Still the combinatorial explosion due to adding new components is inevitable.

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 7 Problem with the Virtual Memory 0x000…000 0xFFF…FFF Virtual Address Space Memory Page

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 8 External Memory Model (Aggarwal and Vitter) Input of size N and N >> M M B Disk If the input size is very large, running time depends on the I/Os rather than on the number of instructions. Scan(N) = O(N / B) Sort(N) = O(N/B log M/B N/B)

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 9 External Breadth-First Search for Explicit Graphs (Munagala & Ranade, SODA-99) A t t+1 t+2 BCDBCD XYZAXXYZAX AXYZAXYZ XYZXYZ Duplicates’ Removal I: Remove Duplicates by sorting the nodes according to the indices and doing an scan and compaction phase. II: Subtract layers t and t+1 from t+2.

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 10 External Breadth-First Branch-and-Bound in UPPAAL-CORA Can we use the same approach by Munagala and Ranade here ? YES and NO Duplicate Elimination is not trivial! A A Search frontier Trivial state spaces (l,Z1) (l,Z2) (l,Z3) (l,Z4) (l,Z5) (l,Z6) A state (l,Z) is a duplicate of (l,Z’) iff Z  Z’ and f(Z)  f(Z’) Zone Union – same location but different zones  costcost l: active locations in local automata Z: Zone - set of constraints satisfied by clocks No total order on Zones => O(n^2) comparisons for each location Real-Time state spaces

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 11 Bucket A Bucket is a set of states, residing on the disk, having the same g value,  Where, g = number of transitions needed to transform the initial state to the states of the bucket, No state is inserted again in a bucket that is expanded. If Active (being read or written), represented internally by a small buffer. File on disk Buffer in internal memory Insert state when full, sort and flush

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 12 I/O Complexity of Breadth-First Branch- and-Bound Assumption: At least two zone unions can fit into the main memory. Expansion: O(scan(|V|)) I/Os Duplicates Removal:  Stage 1: Removal of duplicates within a layer. O(sort(|E|) I/Os for sorting, O(scan(|E|) I/Os for scanning and compacting.  Stage 2: Removal of duplicates wrt previous layers. Depends on the locality of the graph – the longest back-edge locality(G) x scan(|V|) I/Os Cumulative Complexity:  O(sort(|E|) + locality(G) x scan(|V|) I/Os.

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 13 External Breadth-First Branch-and-Bound

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 14 Problems with Breadth-First BnB Too much efforts until some solution is found. Solution:  Explore partial space to search for some solution.  Increase the coverage of the space and improve the solution. Iterative Broadening External Breadth-First BnB

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 15 Iterative Broadening External Breadth- First BnB costcost Search frontier k=20% 40% 60% 80% 100% Only pick best k% nodes for expansion.

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 16 Selection Criteria How can we guarantee that the solution will be improved or at least remain the same ?  Possible if Selection Criteria:  Best k% of the nodes PLUS  All the states that have the same cost as that of the last state of the selected list PLUS  All the sates that have the cost smaller or equal to the maximum cost selected in the previous iteration. i: layer number l: iteration Select the whole cost plateau Select all plateaus from the previous iteration

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 17 Iterative Broadening External BF BnB

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 18 Aircraft Landing Scheduling Problem 1 runway 10 planes Beam Width in % Given Upper Bound New Upper BoundExpanded States 1 ∞ ∞ 70031,458 External Breadth-First BnB

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 19 Aircraft Landing Scheduling Problem 2 runway 20 planes Beam Width in % Given Upper Bound New Upper BoundExpanded States 0.1 ∞ 19401, , , , , , ∞ -- Out-of-space with External Breadth- First BnB

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 20 Alternate Modeling of Aircraft Landing Scheduling (Dierks, VVPS’05) 3 runways but 13 clocks External Breadth- First BnB Harddisk usage = 311 Gigabytes RAM usage = 1.8 Gigabytes Time = 12 hours Iterative Broadening did not pay off due to large cost plateaus Incomplete exploration due to space constraints.

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 21 Issues in External Exploration Error trace:  No predecessor pointers!  Save the predecessor with each state.  Trace back from the goal state to the start state breadth- wise. Disk space eaten by duplicate states:  Start “Early” Delayed Duplicate Detection

Edelkamp and Jabbar (Dortmund) Real-time Model Checking on Secondary Storage 22 Summary & Outlook Contribution  External storage can provide the facility to save open and closed lists.  Iterative broadening strategy can outperform simple breadth-first branch-and-bound. Future Work  Externality => promising for distributed execution by distributing a layer on multiple processors.  Can pause-and-resume your execution to add more harddisks.  Completely orthogonal - Can be combined with other state- space reduction techniques.