Upload
philomena-peters
View
221
Download
0
Tags:
Embed Size (px)
Citation preview
Models for Deterministic Execution of Real-timeMultiprocessor Applications
Peter Poplavko, Dario Socci, Paraskevas Bourgos, Saddek Bensalem, Marius Bozga
VERIMAG lab (CNRS, University of Grenoble)
Research supported by the European ICT Collaborative Project no. 288175(CERTAINTY) and no. 332987 (ARROWHEAD).
2
I. Fixed Priority Process Networks - FPPN • Motivation • Model of computation
• KPN + synchronous events + priorities
II. Approximately static subclass of FPPN• Static scheduling• Online scheduling policy
Implementation and experimentsConclusions
Models for Multiprocessor Applications
Petro Poplavko / VERIMAG Grenoble11-Mar-15
3
• Many industrial designs use fixed priority• schedulability analysis tools, programming language
support (ADA) and… deterministic communication
Fixed Priority Process Networks
Petro Poplavko / VERIMAG Grenoble11-Mar-15
• ????• … under the condition of short enough execution times
(not safe, but often holds for control apps)
• … valid restrictions on task set, e.g. Audsley’s approach for static task graphs [RTNS12]
4
• Functionally deterministic models:• Kahn process networks and dataflow
streaming applications• Synchronous languages
reactive applications
Fixed Priority Process Networks
11-Mar-15 Petro Poplavko / VERIMAG Grenoble
streaming + reactive?• Reactive Process Networks (RPN) deterministic and timed behavior ?
=> add priorities and synchronous events
5
• Functionally deterministic models:• Kahn process networks and dataflow
streaming applications• Synchronous languages
reactive applications
Fixed Priority Process Networks
11-Mar-15 Petro Poplavko / VERIMAG Grenoble
FPPN is a combinationstreaming + reactive?• Reactive Process Networks (RPN) deterministic and timed behavior ?
=> add priorities and synchronous events
Petro Poplavko / VERIMAG Grenoble 6
Representative Example
11-Mar-15
InputA1 per 200ms
FilterB200ms
CoefB≤ 2 per 700ms
functional priority (at each channel)FIFOsporadic process
periodic process
Input Channel
FilterA100ms
OutputA200ms
NormA200ms
blackboard (shared variable)
OutputB100ms
Output Channel 1
Output Channel 2
burst size and inter-arrival
7
FPPN: unexpected facts
11-Mar-15 Petro Poplavko / VERIMAG Grenoble
• Channels are non-blocking
• Non-FIFO channels are allowed• FIFO, blackboard, user-defined…
• Processes = RTS tasks• sporadic / periodic / others…• deadline , inter-arrival time • any “classical” independent task set can be seen as FPPN
without channels
• Processes are synchronous• global time• simultaneously arriving / non-arriving
8
Relative order of execution
11-Mar-15 Petro Poplavko / VERIMAG Grenoble
precedence between communicating jobs:• follow the arrival times• simultaneous arrival => apply priority
dynamically constructed precedence graph
sporadic A sporadic B
time
A[1](0,2000)
A[2](10,2010)
B[1](20,3020)
B[3](70,3070)
A[3](70,2070)
B[2](50,3050)
FilterB[1](0,200)
OutputB[1](0,100)
InputA[1](0,200)
FilterA[1](0,100)
OutputA[1](0,200)
CoefB[1](0,200)
CoefB[2](0,200)
FilterA[2](100,200)
NormA[1](0,200)
OutputB[2](100,200)
p i [k i](A i , D i )
Restriction and static approximation
11-Mar-15 Petro Poplavko / VERIMAG Grenoble 10
FilterB200ms
CoefB≤ 2 per700ms
every sporadic process
periodic server user period
unique periodic “user” process
OutputB[1]
M1 InputA[1] FilterA[1] OutputA[1]
COEFB[1]
FilterA[2]
OutputB[2]
100 ms -arrival0 arrival
M2 FilterB[1]
11-Mar-15 Petro Poplavko / VERIMAG Grenoble 11
…can be scheduled by List Scheduling
• easy, fast but sub-optimal (work conserving)
• better heuristics:
• topological permutation [PRORISC2000]
• force-directed scheduling
200 ms cycle
COEFB[2]
NormA[2]
11-Mar-15 Petro Poplavko / VERIMAG Grenoble 12
Online policy illustrated by Petri Net
wait 0+cyc wait 100+cyc cyc:= cyc+200
OutputB[1]
M1 InputA[1] FilterA[1] OutputA[1]
COEFB[1]
FilterA[2]
OutputB[2]
100 ms -arrival0 arrival
M2 FilterB[1]
200 ms cycle
COEFB[2]
NormA[2]
11-Mar-15 Petro Poplavko / VERIMAG Grenoble 13
wait 0+cyc wait 100+cyc
Online policy and sporadic jobs
cyc:= cyc+200
wait 0+cyc sporadic jobs
up to 2 jobs/ period
-200+cyc 0+cyc
periodic server:𝕋 and 𝔽 tokens
𝔽 ; 𝔽𝕋 ; 𝔽𝕋 ; 𝕋
Utilization metric?
(0,200 , 25) (0,100 , 25)
(0,200 , 25) (0,100 , 25) (0,200 , 25)
(0,200, 5) (0,200 , 5)
(100,200 , 25) (0,200 , 5)
(100,200 , 25)
11-Mar-15 Petro Poplavko / VERIMAG Grenoble 14
p i [k i](A i , D i , C i ) Load:
This example: 95%
p i [k i](A* i , D*i , C i ) Load*:
This example: 110%5
10 35
100
200
175
200
0
Implementation (public domain)
11-Mar-15 Petro Poplavko / VERIMAG Grenoble 15
Application (FPPN+C)
Compile Application Compile Scheduling
StaticSchedule
BIP Compiler
Executable
Application + Scheduler (BIP)
BIP RTE
FFT2_0_1
generator
FFT2_0_2
FFT2_0_3
FFT2_0_0
FFT2_1_1
FFT2_1_2
FFT2_1_3
FFT2_1_0
FFT2_2_1
FFT2_2_2
FFT2_2_3
FFT2_2_0
consumer
11-Mar-15 Petro Poplavko / VERIMAG Grenoble 16
Case Study1: FFT Transform
Kalray MPPA 256 Platform
Load* = 93% 120 % (with RT overhead)
SensorInput200ms
AnemoConfig2 per200ms
GPSConfig2 per200ms
IRSConfig2 per200ms
DopplerConfig2 per200ms
HighFreqBCP200ms
LowFreqBCP5000ms
MagnDeclin1600ms
BCPConfig2 per200ms
Performance1000ms
MagnDeclinConfig5 per1600ms
PerformanceConfig5 per1000ms
AnemoDataGPSDataIRSData
DopplerData
PerformanceData
BCP Data
RM relative priority
11-Mar-15 Petro Poplavko / VERIMAG Grenoble 18
Flight Management System (Thales)
11-Mar-15 Petro Poplavko / VERIMAG Grenoble 19
Flight Management System (Thales)
Linux Intel i7 3.6 GHz platform
Static task graph: 812 nodes, 1977 edges
Load* = 23%
11-Mar-15 Petro Poplavko / VERIMAG Grenoble 20
Related work
FPPN combines certain concepts of synchronous andstreaming languages - PRELUDE-SCHEDMCORE
synchronous language and multi-core scheduling - OIL – streaming language with timing constraints - Algorithms for scheduling task graph for synchronous systems
- Reactive Process Networks
11-Mar-15 Petro Poplavko / VERIMAG Grenoble 21
Conclusions
• FPPN – model of computation for reactive + streaming applications
• Generalizing the determinism of uniprocessor fixed-priority systems to multi-processors
• Approximately static subclass:
• task graph derivation
• scheduling algorithm
• scheduling policy and utilization metric
• two use cases