Periodic Task Scheduling

Slides:



Advertisements
Similar presentations
Fakultät für informatik informatik 12 technische universität dortmund Classical scheduling algorithms for periodic systems Peter Marwedel TU Dortmund,
Advertisements

Washington WASHINGTON UNIVERSITY IN ST LOUIS Real-Time: Periodic Tasks Fred Kuhns Applied Research Laboratory Computer Science Washington University.
Chapter 7 - Resource Access Protocols (Critical Sections) Protocols: No Preemptions During Critical Sections Once a job enters a critical section, it cannot.
1 EE5900 Advanced Embedded System For Smart Infrastructure RMS and EDF Scheduling.
B. RAMAMURTHY 4/13/2015 cse321-fall2014 Realtime System Fundamentals : Scheduling and Priority-based scheduling Pag e 1.
CS5270 Lecture 31 Uppaal, and Scheduling, and Resource Access Protocols CS 5270 Lecture 3.
Resource Access Protocols
CPE555A: Real-Time Embedded Systems
THE UNIVERSITY of TEHRAN Mitra Nasri Sanjoy Baruah Gerhard Fohler Mehdi Kargahi October 2014.
Real-time concepts Lin Zhong ELEC424, Fall Real time Correctness – Logical correctness – Timing Hard vs. Soft – Hard: lateness is intolerable Pass/Fail.
From HRT-HOOD to ADA95 Real-Time Systems Lecture 5 Copyright, 2001 © Adam Czajka.
Real-Time Scheduling CIS700 Insup Lee October 3, 2005 CIS 700.
1 Swiss Federal Institute of Technology Computer Engineering and Networks Laboratory Embedded Systems Exercise 2: Scheduling Real-Time Aperiodic Tasks.
Module 2 Priority Driven Scheduling of Periodic Task
CPU SCHEDULING RONG ZHENG. OVERVIEW Why scheduling? Non-preemptive vs Preemptive policies FCFS, SJF, Round robin, multilevel queues with feedback, guaranteed.
Problem 11: Complex Hierarchical Scheduling Full Processor FP T3T2 T4T1 EDF T6T5 RM T10T9T8T7 EDFSPS DPS 10 Tasks - with jitter - with bursts - deadline.
Courseware Scheduling Uniprocessor Real-Time Systems Jan Madsen Informatics and Mathematical Modelling Technical University of Denmark Richard Petersens.
Preemptive Behavior Analysis and Improvement of Priority Scheduling Algorithms Xiaoying Wang Northeastern University China.
Real-Time System: Introduction
Roadmap  Introduction  Concurrent Programming  Communication and Synchronization  Completing the Java Model  Overview of the RTSJ  Memory Management.
Fakultät für informatik informatik 12 technische universität dortmund Classical scheduling algorithms for periodic systems Peter Marwedel TU Dortmund,
EE 249, Fall Discussion: Scheduling Haibo Zeng Amit Mahajan.
Embedded Systems Exercise 3: Scheduling Real-Time Periodic and Mixed Task Sets 18. May 2005 Alexander Maxiaguine.
Aperiodic Task Scheduling
Scheduling Algorithms for Multiprogramming in a Hard-Real-Time Environment Presented by Pete Perlegos C.L. Liu and James W. Layland.
By Group: Ghassan Abdo Rayyashi Anas to’meh Supervised by Dr. Lo’ai Tawalbeh.
Misconceptions About Real-time Computing : A Serious Problem for Next-generation Systems J. A. Stankovic, Misconceptions about Real-Time Computing: A Serious.
Scheduling Algorithms for Multiprogramming in a Hard-Real-Time Environments.
Chapter 4 – Periodic Task Scheduling In many real-time systems periodic tasks dominate the demand. Three classic periodic task scheduling algorithms: –
Technische Universität Dortmund Classical scheduling algorithms for periodic systems Peter Marwedel TU Dortmund, Informatik 12 Germany 2007/12/14.
Real-Time Embedded Software Synthesis 即時嵌入式軟體合成 熊博安國立中正大學資訊工程學系民國九十年十一月廿九日.
Quantifying the sub-optimality of uniprocessor fixed priority non-pre-emptive scheduling Robert Davis 1, Laurent George 2, Pierre Courbin 3 1 Real-Time.
Real-Time Scheduling CS4730 Fall 2010 Dr. José M. Garrido Department of Computer Science and Information Systems Kennesaw State University.
Scheduling policies for real- time embedded systems.
Multiprocessor Real-time Scheduling Jing Ma 马靖. Classification Partitioned Scheduling In the partitioned approach, the tasks are statically partitioned.
資工系網媒所 NEWS 實驗室 Paper Discussion C. L. Liu and James W. Layland, "Scheduling Algorithms for Multiprogramming in a Hard-Real- Time Environment", JACM, Vol.
National Taiwan University Department of Computer Science and Information Engineering 1 Optimal Real-Time Scheduling for Uniform Multiprocessors 薛智文 助理教授.
CS Spring 2011 CS 414 – Multimedia Systems Design Lecture 31 – Multimedia OS (Part 1) Klara Nahrstedt Spring 2011.
Real-Time Scheduling CS4730 Fall 2010 Dr. José M. Garrido Department of Computer Science and Information Systems Kennesaw State University.
Real-Time Scheduling CS 3204 – Operating Systems Lecture 20 3/3/2006 Shahrooz Feizabadi.
CS244-Introduction to Embedded Systems and Ubiquitous Computing Instructor: Eli Bozorgzadeh Computer Science Department UC Irvine Winter 2010.
6. Application mapping 6.1 Problem definition
RTOS task scheduling models
- 1 -  P. Marwedel, Univ. Dortmund, Informatik 12, 2006 Universität Dortmund Periodic scheduling For periodic scheduling, the best that we can do is to.
CprE 458/558: Real-Time Systems (G. Manimaran)1 CprE 458/558: Real-Time Systems RMS and EDF Schedulers.
CS244-Introduction to Embedded Systems and Ubiquitous Computing Instructor: Eli Bozorgzadeh Computer Science Department UC Irvine Winter 2010.
Special Class on Real-Time Systems
CSE 522 Real-Time Scheduling (2)
Real Time Operating Systems Schedulability - Part 2 Course originally developed by Maj Ron Smith 12/20/2015Dr Alain Beaulieu1.
Real-Time Scheduling CS 3204 – Operating Systems Lecture 13 10/3/2006 Shahrooz Feizabadi.
1 Real-Time Scheduling. 2Today Operating System task scheduling –Traditional (non-real-time) scheduling –Real-time scheduling.
Dynamic Priority Driven Scheduling of Periodic Task
Classical scheduling algorithms for periodic systems Peter Marwedel TU Dortmund, Informatik 12 Germany 2012 年 12 月 19 日 These slides use Microsoft clip.
Mok & friends. Resource partition for real- time systems (RTAS 2001)
2/23/2016COSC , Lecture 21 Real-Time Systems, COSC , Lecture 2 Stefan Andrei.
Undergraduate course on Real-time Systems Linköping University TDDD07 Real-time Systems Lecture 2: Scheduling II Simin Nadjm-Tehrani Real-time Systems.
Fault-Tolerant Rate- Monotonic Scheduling Sunondo Ghosh, Rami Melhem, Daniel Mosse and Joydeep Sen Sarma.
Lecture 6: Real-Time Scheduling
Embedded System Scheduling
Scheduling and Resource Access Protocols: Basic Aspects
Unit OS9: Real-Time and Embedded Systems
Lecture 24: Process Scheduling Examples and for Real-time Systems
Realtime Scheduling Algorithms
Real Time Scheduling Mrs. K.M. Sanghavi.
NET 424: REAL-TIME SYSTEMS (Practical Part)
NET 424: REAL-TIME SYSTEMS (Practical Part)
Real-Time Process Scheduling Concepts, Design and Implementations
Ch 4. Periodic Task Scheduling
Real-Time Process Scheduling Concepts, Design and Implementations
Real-Time Scheduling David Ferry CSCI 3500 – Operating Systems
Presentation transcript:

Periodic Task Scheduling 張軒彬助理教授 中興大學資訊科學系 In this chapter, we introduce the periodic task scheduling. Periodic activities represent the major computational demand in most real-time systems. For example, sensory data acquisition, control loops, system monitoring are all periodic tasks.

Outline Processor Utilization Factor Rate Monotonic Scheduling Earliest Deadline First In this chapter, we first introduce the processor utilization factor. Then, three periodic tasks scheduling algorithms, Rate Monotonic and Earliest Deadline First, are described sequentially.

Processor Utilization Factor Given a set T of n periodic tasks, processor utilization factor U is the fraction of processor time spent in the execution of a task set There exists a maximum value of U below which T is schedulable and above with T is not schedulable Depend on the task set and used scheduling algorithm Let Uub(T, A) denote the upper bound of the processor utilization factor for a task set T under a give algorithm A If U = Uub(T, A), the set T is said to fully utilize the processor Definition: Processor Utilization Factor Given a set T of n periodic tasks, processor utilization factor U is the fraction of processor time spent in the execution of a task set Where Ci is task i’s computation time and Ti is its period. From the definition, processor utilization factor provides a measure of the CPU’s computational load due to the periodic task set. Depend on the task set and applied scheduling algorithm, there exists a maximum value of U which task set T is schedulable and above with T is not schedulable.

Processor Utilization Factor (Cont.) For a given algorithm A, the least upper bound Ulub(A) of the processor utilization factor is the minimum of the utilization factors over all task sets that fully utilize the processor Uub1 T1 Uub2 The definitions of upper bound and the lease upper bound of the processor utilization factor are shown in the slides. Example: as shown in the figure, each task set Ti differ in the number of tasks and their periods. Each task set may have different upper bound and the minimum one of is the least upper bound. T2 Uub3 T3 Uub4 T4 Uubm Tm U 1 Ulub

Processor Utilization Factor (Cont.) Ulub(A) defines an important characteristics of a real-time scheduling algorithm. It allow to easily verify the schedulability of a task set. If a task set whose processor utilization factor is below Ulub(A), then it is schedulable by the algorithm A. In contrast, if a task set’s processor utilization factor is above Ulub(A), it may or may not be schedulable by the algorithm A

Rate Monotonic Scheduling Task model: Periodic tasks Arbitrary arrival times Different computation time and deadlines Preemptive This slide shows the task model of Rate Monotonic.

Rate Monotonic Scheduling (Cont.) Rate Monotonic (RM) Assign priorities to tasks according to their request rates Tasks with higher request rates, i.e., shorter periods, have higher priorities Fixed-priority scheduling algorithm Priority are assigned to tasks before execution and do not change over time Intrinsically preemptive The currently executing task is preempted by a newly arrived task with shorter period

Rate Monotonic Scheduling (Cont.) Optimality: RM is optimal among all fixed-priority scheduling algorithms No other fixed-priority algorithm can schedule a task set that cannot be scheduled by RM Schedulability condition: given n tasks, the least upper bound of the processor utilization factor under RM is In 1973, Liu and Layland showed that RM is optimal among all fixed-priority scheduling algorithms since no other fixed-priority algorithm can schedule a task set that cannot be scheduled by RM. The least upper bound of the processor utilization factor in RM is n 1 2 3 4 5 6 7 8 9 10 Ulub 1.000 0.828 0.780 0.757 0.743 0.735 0.729 0.724 0.721 0.718

Rate Monotonic Scheduling (Cont.) Concluding remarks The schedulability condition is sufficient to guarantee the feasibility of any task set, but it is not necessary Thus, if a task set has an utilization factor greater than Ulub and less than one, nothing can be said on the feasibility of the task set

Earliest Deadline First Earliest Deadline First (EDF) Selects tasks according to their (absolute) deadlines Tasks with earlier deadlines will be executed at higher priority Dynamic scheduling algorithm The absolute deadline of a periodic task depends on the current ith instances Thus, EDF is a dynamic priority assignment Intrinsically preemptive The current executing task is preempted whenever another periodic instance with earlier deadline become active

Earliest Deadline First (Cont.) Optimality: EDF is optimal among all dynamic-priority scheduling algorithms Schedulability analysis A set of periodic tasks is schedulable with EDF if and only if

Example Two tasks: Processor utilization factor Task 1: execution time: 2, period: 5 Task 2: execution time: 4, period: 7 Processor utilization factor U = 2/5 + 4/7 = 0.97 U > Ulcb of RM RM cannot guarantee schedulability U < Ulcb(=1) of EDF EDP thus guarantee schedulability

Example RM T1 5 10 15 20 25 30 35 time overflow T2 7 14 21 28 35 EDF Example, a task set whose processor utilization factor is 2/5 + 4/7 = 34/35 ~ 0.97. Thus, the CPU spends its 97% of time in executing periodic tasks with 3% of time idle. Since U > ln2, thus, the task set’s schedulability is not guaranteed in RM. Indeed, RM results in a miss deadline at t = 7. In contrast, U < 1, thus the task set is schedulable under EDF. T1 5 10 15 20 25 30 35 T2 7 14 21 28 35

Reference Giorgio C. Buttazzo, “Hard Real-Time Computing Systems: Predictable Scheduling Algorithms and Applications,” Kluwer Academic Publishers, 1997 Jane W. S. Liu, “Real-Time Systems,” Prentice Hall, 2002