Writing at the Intermediate Level: Modes & Standards Cori Anderson University of Chicago.
Combining Task-level and System-level Scheduling Modes for...
Transcript of Combining Task-level and System-level Scheduling Modes for...
![Page 1: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/1.jpg)
Combining Task-level and System-levelScheduling Modes for Mixed Criticality Systems
DS-RT 2019, Cosenza Italy, 2019-10-08
Jalil Boudjadar1
Saravanan Ramanathan2 and Arvind Easwaran2
Ulrik Nyman3 [email protected]
1Aarhus University, Denmark
2Nanyang Technological University, Singapore
3Distributed, Embedded and Intelligent Systems, DEISDepartment of Computer Science
Aalborg University, Denmark
![Page 2: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/2.jpg)
Combining Task-level and System-level Scheduling Modesfor Mixed Criticality Systems
![Page 3: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/3.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
1Setting and Purpose
Mixed-critical systemsI High criticality tasks (HC)I Low criticality tasks (LC)
I HC tasks should never miss a deadlineI Dropping as few LC tasks as possible
![Page 4: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/4.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
1Setting and Purpose
Mixed-critical systemsI High criticality tasks (HC)I Low criticality tasks (LC)I HC tasks should never miss a deadlineI Dropping as few LC tasks as possible
![Page 5: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/5.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
2Related WorkTwo approaches
System-level modeI Two system modes
I NormalI Critical
I Drop all LC tasksI Run LC tasks in degraded mode
Task-level mode
I Each HC task switches individually to CriticalI Other HC tasks can miss their deadline
![Page 6: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/6.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
2Related WorkTwo approaches
System-level modeI Two system modes
I NormalI Critical
I Drop all LC tasksI Run LC tasks in degraded mode
Task-level mode
I Each HC task switches individually to CriticalI Other HC tasks can miss their deadline
![Page 7: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/7.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
2Related WorkTwo approaches
System-level modeI Two system modes
I NormalI Critical
I Drop all LC tasksI Run LC tasks in degraded mode
Task-level modeI Each HC task switches individually to Critical
I Other HC tasks can miss their deadline
![Page 8: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/8.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
2Related WorkTwo approaches
System-level modeI Two system modes
I NormalI Critical
I Drop all LC tasksI Run LC tasks in degraded mode
Task-level modeI Each HC task switches individually to CriticalI Other HC tasks can miss their deadline
![Page 9: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/9.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
3Assumptions
I Tasks are preemptible.I All tasks are assigned a static criticality level (LC or HC) by
design, called default criticality.I The execution of a HC task must not be discarded under any
runtime circumstances.I The runtime criticality of a LC task can never be upgraded to HC.I LC tasks stick always to their low confidence WCET.I There is no dependency between LC and HC tasks.
![Page 10: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/10.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
4Task
A task πi is given by 〈Ti ,C li ,C
hi , χi , ρ〉 where:
I Ti is the task period.I C l
i ∈ R≥0 and Chi ∈ R≥0 are the worst case execution time for low
and high confidence levels respectively. We assume thatCh
i ≥ C li for HC tasks, and Ch
i = C li for LC tasks.
I χi ∈ LC,HC is the default (constant) criticality of the task.I ρ is the task priority.
The task runtime mode Ω() will be updated on the fly according to theactual task execution budget.
![Page 11: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/11.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
5Task types
I Types of tasksHC LC
Type High criticality Low criticalityModes HI and LO no modesWCET Varies Ch
i ≥ C li Static Ch
i = C li
I Modes for HC tasksHI LO
WCET Chi C l
i
![Page 12: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/12.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
5Task types
I Types of tasksHC LC
Type High criticality Low criticalityModes HI and LO no modesWCET Varies Ch
i ≥ C li Static Ch
i = C li
I Modes for HC tasksHI LO
WCET Chi C l
i
![Page 13: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/13.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
6Three scheduling functions
I Fixed priority scheduling Sched : 2Π × R≥0 → ΠI Intermediate scheduling
Sched I(Π, t) = πi |Ready(πi , t) ∧ ∀πj ∈ Π Ready(πj , t)⇒ Ω(πj , t) < Ω(πi , t)∨Ω(πj , t) = Ω(πi , t) ∧ Sched(πi , πj, t) = πi
I Critical scheduling
SchedC(Π, t) = πi |Ready(πi , t) ∧ ∀πj ∈ Π Ready(πj , t)⇒
χj < χi∨(χj = χi ) ∧ Ω(πj , t) < Ω(πi , t)∨(χj = χi ) ∧ (Ω(πj , t) = Ω(πi , t))
∧ Sched(πi , πj, t) = πi
![Page 14: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/14.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
7System scheduling mode behavior
Criticalmode
Normal mode
Workload (when all HC tasks run Ch) exceeds Threshold
At least one HC task terminated
![Page 15: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/15.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
8ExampleSimple mixed task set
Task T C l Ch χ ρπ1 20 5 7 HC 2π2 20 5 6 HC 4π3 20 5 - LC 1π4 20 4 - LC 3
![Page 16: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/16.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
9ExampleRuntime example for the system in Table
π1
π2
π3
π4
Ω=LOLO
Ω=LOLO
Ω=LOHI
Cl overrun
ρ =LO 2
ρ =LO 4
ρ =LO 1
ρ =LO 3
![Page 17: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/17.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
10Low criticality task behavior
Active (stretched
period)
Active (regular)
Active (shrunk period)
System scheduling-mode switched to Critical
Period stretching
Period shrinking
![Page 18: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/18.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
11High criticality task behavior
Active (HI mode)
Active (LO mode)
WCET Cl violation
Period termination
![Page 19: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/19.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
12Example of LC task periods shrinking
System mode:
HC task π1: (T=30,C=7)
LC task π2:(T=20, C=4)
LC task π3:(T=14,C=3)
StretchingRegularShrinking
CriticalNormal
StretchingRegularShrinking
HI modeLO mode
5
30
Shrinking with ∆=12 over interval[5,30]
7
8
3521
µ=6
µ=4
3818 28
![Page 20: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/20.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
13Algorithm
![Page 21: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/21.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
14Case studyOrigin
I Task set from[14] R. Dodd. Coloured petri net modelling of a generic avionics
missions computer. Technical report, Department of Defence,Australia, Air Operations Division, 2006.
I WCET (C l ) given in original case.I WCET (Ch) calculated from data fetching times.
I 20µs for data wordsI 40µs for a commandI 40µs for a status
![Page 22: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/22.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
15Case studyTasks
Task χ T C l Ch ρAircraft flight data(π1) HC 55 8 8.9 6Steering(π2) HC 80 6 6.3 9Target tracking(π3) HC 40 4 4.2 3Target sweetening(π4) HC 40 2 2 4AUTO/CCIP toggle(π5) HC 200 1 1 12Weapon trajectory(π6) HC 100 7 7.5 10Reinitiate trajectory(π7) LC 400 6.5 - 14Weapon release(π8) HC 10 1 1.2 1HUD display(π9) LC 52 6 - 7MPD tactical display(π10) LC 52 8 - 8Radar tracking(π11) HC 40 2 2.2 2HOTAS bomb button (π12) LC 40 1 - 5Threat response display(π13) LC 100 3 - 11Poll RWR(π14) LC 200 2 - 13Perodic BIT(π15) LC 1000 5 - 15
![Page 23: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/23.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
16Case StudyUppaal model
![Page 24: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/24.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
17Case StudyResults
I Not schedulable with classical fixed priority schedulingI tasks π10 and π11 miss their deadlines
I Not schedulable with task-level mode schedulingI task π10 misses its deadline (response time 106)
I System-level scheduling vs. our algorithm
![Page 25: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/25.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
18Case studyExperimental results
![Page 26: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/26.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
19Case studyExperimental results
I Discard rate of the LC task jobs achieved by our algorithm is1.0% to 4.58%
I Discard rate achieved by the state of the art system-levelbi-mode scheduling [13], [33] is 2.1% to 11.5%.
[13] D. de Niz, K. Lakshmanan, and R. Rajkumar. On the scheduling of mixed-criticality real-timetask sets. In RTSS’09, pages 291–300, 2009.
[33] B. Madzar, J. Boudjadar, J. Dingel, T. E. Fuhrman, and S. Ramesh. Formal analysis ofpredictable data flow in fault-tolerant multicore systems. In FACS ’16, pages 153–171, 2016
![Page 27: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/27.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
20Conclusion
And future work
ConclusionI Flexible multi-mode scheduling for mixed-criticality systems
I accurate and non-aggressive system mode switchesI Stretching of periodsI Much less dropping of LC tasksI Too computation heavy at the moment
Future WorkI Real implementationI Optimization of algorithm overhead
![Page 28: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/28.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
20ConclusionAnd future work
ConclusionI Flexible multi-mode scheduling for mixed-criticality systems
I accurate and non-aggressive system mode switchesI Stretching of periodsI Much less dropping of LC tasksI Too computation heavy at the moment
Future WorkI Real implementationI Optimization of algorithm overhead
![Page 29: Combining Task-level and System-level Scheduling Modes for ...ulrik.blog.aau.dk/files/2017/05/DS-RT-presentation.pdf · Combining Task-level and System-level Scheduling Modes for](https://reader034.fdocuments.us/reader034/viewer/2022051806/5ffd2bc87d40dc035a3f6da6/html5/thumbnails/29.jpg)
Jalil Boudjadar Saravanan Ramanathan and Arvind Easwaran Ulrik Nyman [email protected] |Combining Task-level and System-level Scheduling Modes for Mixed Criticality Systems
21Questions?
System mode:
HC task π1: (T=30,C=7)
LC task π2:(T=20, C=4)
LC task π3:(T=14,C=3)
StretchingRegularShrinking
CriticalNormal
StretchingRegularShrinking
HI modeLO mode
5
30
Shrinking with ∆=12 over interval[5,30]
7
8
3521
µ=6
µ=4
3818 28
Active (stretched
period)
Active (regular)
Active (shrunk period)
System scheduling-mode switched to Critical
Period stretching
Period shrinking