Parking Can Get You There Faster Model Augmentation to Speed up Real-Time Model Checking Oliver M¨ oller BRICS University of Aarhus, Denmark omoeller@brics.dk 1 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Timed Automata ( U PPAAL Flavor) x > LARGE T y := 0 S y <= 0 x <= LARGE x < 10 y == 10 QUICK y <= 10 clocks: x,y guards: y==10, x > LARGE, x < 10 invariants: y < =10 urgency: location S 2 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Timed Automata ( U PPAAL Flavor) x > LARGE T y := 0 S y <= 0 x <= LARGE x < 10 y == 10 QUICK y <= 10 network of timed automata clocks: x,y hand-shake synchronization guards: y==10, x > LARGE, x < 10 discrete data types invariants: y < =10 urgency: location S ... 3 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Symbolic Forward Reachability n x > 3 y := 0 m 4 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Symbolic Forward Reachability y 1 <= x <= 4 1 <= y <= 2 n x x > 3 y := 0 m 5 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Symbolic Forward Reachability y y 1 <= x <= 4 1 <= x 1 <= y <= 2 1 <= y delays to n -2 <= x-y <= 3 x x x > 3 y y := 0 x m 6 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Symbolic Forward Reachability y y 1 <= x <= 4 1 <= x 1 <= y <= 2 1 <= y delays to n -2 <= x-y <= 3 x x x > 3 y y 3 < x 1 <= y intersects to -2 <= x-y <= 3 y := 0 x x y 3 < x 1 <= y m -2 <= x-y <= 3 x 7 TPTS’01 7 A PRIL 2002 O LIVER M ¨ OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Symbolic Forward Reachability y y 1 <= x <= 4 1 <= x 1 <= y <= 2 1 <= y delays to n -2 <= x-y <= 3 x x x > 3 y y 3 < x 1 <= y intersects to -2 <= x-y <= 3 y := 0 x x y y 3 < x 1 <= y 3 < x projects to m y = 0 -2 <= x-y <= 3 x x 8 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Forward State Space Exploration Algorithm: Reachability Goal : ( � input: l g ; v g ) l 0 ; v ↑ � Passed := {} ; Waiting := { ( � l 0 0 ) } R EPEAT F ORALL ( � l ; v ) ∈ Waiting l ; v ′ ) ∈ Passed .v �⊆ v ′ T HEN I F ∀ ( � Passed := Passed ∪ ( � l ; v ) g,r F ORALL ( � l ′ ; v ′ ) with � → � l ′ − l v ′ := r ( v ∩ g ) v ′ � = ∅ l ′ ; v ′↑ � Waiting := Waiting ∪ { ( � l ′ ) } U NTIL Waiting = ∅ ∨ ∃ ( � l, v ) ∈ Passed .� l g ⊆ � l ∧ v g ∩ v � = ∅ 9 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Problem: Repetitions in the State-Space y x > LARGE T y := 0 S y <= 0 x <= LARGE x < 10 y == 10 QUICK y <= 10 x LARGE T is visited repeatedly state space at control point T 10 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Outline 1 Model Augmentation Technique 2 Application to RCX Bricks Sorter Model 3 Extension to Universal Path Properties 11 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Idea: Subsume Many Small Steps by a Big One y x > LARGE T y := 0 S y <= 0 x <= LARGE x < 10 y == 10 QUICK y <= 10 x LARGE 12 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Idea: Subsume Many Small Steps by a Big One y y x > LARGE T y := 0 S y <= 0 x <= LARGE x < 10 y == 10 QUICK y <= 10 x x LARGE LARGE 13 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Idea: Subsume Many Small Steps by a Big One y y AUGMENT x <= LARGE x <= LARGE x > LARGE T T y := 0 S S y <= 0 x <= LARGE x <= LARGE x < 10 x < 10 y == 10 y == 10 QUICK QUICK y <= 10 y <= 10 x x LARGE LARGE new way to reach T state space at control point T 14 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Effect: No Repetitions AUGMENT x <= LARGE x <= LARGE x > LARGE x > LARGE T y := 0 T y := 0 S S y <= 0 y <= 0 x <= LARGE x <= LARGE x < 10 y == 10 x < 10 y == 10 QUICK QUICK y <= 10 y <= 10 #states time[sec] memory[KB] #states time[sec] memory[KB] LARGE 10 8 0.01 376 9 0.01 448 100 35 0.01 440 9 0.01 376 1000 305 0.04 424 9 0.01 440 10 · 000 3 · 005 1 · 704 1.51 9 0.01 440 100 · 000 30 · 005 5 · 440 175.21 9 0.02 416 1 · 000 · 000 300 · 005 22 · 449.94 42 · 792 9 0.02 400 Model Checking: QUICK not reachable 15 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Soundness for Safety Crucial Observation: every trace that was originally possible is also possible after the modification Therefore: if a safety property A[] ϕ can be established for the augmented model Aug A ( M ) , then it also holds for M . 16 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Challenges for Beneficial Augmentation Prerequisites repetitions at one control point all processes can “park” return to the original control structure What to do? find promising augmentation points identify suitable delays construct return conditions 17 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Bricks Sorter Model Sensor Kick-Off Arm ! ? Processes of Sorter: RCX model Scheduler RCX0 main task RCX0 kick off task Environment black brick black brick2 kick off arm Hurry Dummy Objective: Kick off all black bricks, but no red ones 18 O LIVER M ¨ TPTS’01 7 A PRIL 2002 OLLER : P ARKING C AN G ET Y OU T HERE F ASTER
Recommend
More recommend