Misconceptions About Real-time Computing : A Serious Problem for Next-generation Systems J. A. Stankovic, Misconceptions about Real-Time Computing: A Serious.

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

Simulation of Feedback Scheduling Dan Henriksson, Anton Cervin and Karl-Erik Årzén Department of Automatic Control.
Real Time Scheduling.
EE5900 Advanced Embedded System For Smart Infrastructure
Courseware Scheduling of Distributed Real-Time Systems Jan Madsen Informatics and Mathematical Modelling Technical University of Denmark Richard Petersens.
Real-time concepts Lin Zhong ELEC424, Fall Real time Correctness – Logical correctness – Timing Hard vs. Soft – Hard: lateness is intolerable Pass/Fail.
Real-Time Scheduling CIS700 Insup Lee October 3, 2005 CIS 700.
Module 2 Priority Driven Scheduling of Periodic Task
CS 3013 & CS 502 Summer 2006 Scheduling1 The art and science of allocating the CPU and other resources to processes.
Multiprocessor and Real-Time Scheduling Chapter 10.
Courseware Basics of Real-Time Scheduling Jan Madsen Informatics and Mathematical Modelling Technical University of Denmark Richard Petersens Plads, Building.
Fakultät für informatik informatik 12 technische universität dortmund Classical scheduling algorithms for periodic systems Peter Marwedel TU Dortmund,
Embedded Systems Exercise 3: Scheduling Real-Time Periodic and Mixed Task Sets 18. May 2005 Alexander Maxiaguine.
Strategic Directions in Real- Time & Embedded Systems Aatash Patel 18 th September, 2001.
By Group: Ghassan Abdo Rayyashi Anas to’meh Supervised by Dr. Lo’ai Tawalbeh.
CprE 458/558: Real-Time Systems
Spring 2002Real-Time Systems (Shin) Rate Monotonic Analysis Assumptions – A1. No nonpreemptible parts in a task, and negligible preemption cost –
Real-Time Operating System Chapter – 8 Embedded System: An integrated approach.
Technische Universität Dortmund Classical scheduling algorithms for periodic systems Peter Marwedel TU Dortmund, Informatik 12 Germany 2007/12/14.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 15 Slide 1 Real-time Systems 1.
Distributed Real-Time systems 1 By: Mahdi Sadeghizadeh Website: Sadeghizadeh.ir Advanced Computer Networks.
REAL-TIME SOFTWARE SYSTEMS DEVELOPMENT Instructor: Dr. Hany H. Ammar Dept. of Computer Science and Electrical Engineering, WVU.
Binghamton University EngiNet™ State University of New York
MM Process Management Karrie Karahalios Spring 2007 (based off slides created by Brian Bailey)
© Oxford University Press 2011 DISTRIBUTED COMPUTING Sunita Mahajan Sunita Mahajan, Principal, Institute of Computer Science, MET League of Colleges, Mumbai.
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.
Real-Time Systems Mark Stanovich. Introduction System with timing constraints (e.g., deadlines) What makes a real-time system different? – Meeting timing.
Reference: Ian Sommerville, Chap 15  Systems which monitor and control their environment.  Sometimes associated with hardware devices ◦ Sensors: Collect.
BFair: An Optimal Scheduler for Periodic Real-Time Tasks
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.
Aravind Venkataraman. Topics of Discussion Real-time Computing Synchronous Programming Languages Real-time Operating Systems Real-time System Types Real-time.
REAL-TIME SOFTWARE SYSTEMS DEVELOPMENT Instructor: Dr. Hany H. Ammar Dept. of Computer Science and Electrical Engineering, WVU.
CprE 458/558: Real-Time Systems (G. Manimaran)1 CprE 458/558: Real-Time Systems Introduction to Real-Time Systems.
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
Undergraduate course on Real-time Systems Linköping 1 of 45 Autumn 2009 TDDC47: Real-time and Concurrent Programming Lecture 5: Real-time Scheduling (I)
Real Time Systems Real-Time Schedulability Part I.
RTOS task scheduling models
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 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.
CSCI1600: Embedded and Real Time Software Lecture 24: Real Time Scheduling II Steven Reiss, Fall 2015.
Introduction to Embedded Systems Rabie A. Ramadan 5.
A presentation for Brian Evans’ Embedded Software Class By Nate Forman Liaison Technology Inc. 3/30/2000 For Real-Time Scheduling.
CSCI1600: Embedded and Real Time Software Lecture 23: Real Time Scheduling I Steven Reiss, Fall 2015.
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.
Introduction to Real-Time Systems
For a good summary, visit:
Undergraduate course on Real-time Systems Linköping University TDDD07 Real-time Systems Lecture 2: Scheduling II Simin Nadjm-Tehrani Real-time Systems.
1 G53SRP: Introduction to Real Time Scheduling Chris Greenhalgh School of Computer Science.
Unit - I Real Time Operating System. Content : Operating System Concepts Real-Time Tasks Real-Time Systems Types of Real-Time Tasks Real-Time Operating.
Lecture 6: Real-Time Scheduling
Real-Time Operating Systems RTOS For Embedded systems.
Embedded System Scheduling
REAL-TIME OPERATING SYSTEMS
EMERALDS Landon Cox March 22, 2017.
Unit OS9: Real-Time and Embedded Systems
EEE 6494 Embedded Systems Design
Real-time Software Design
CSCI1600: Embedded and Real Time Software
CSCI1600: Embedded and Real Time Software
Processes and operating systems
Ch 4. Periodic Task Scheduling
Real-Time Scheduling David Ferry CSCI 3500 – Operating Systems
Presentation transcript:

Misconceptions About Real-time Computing : A Serious Problem for Next-generation Systems J. A. Stankovic, Misconceptions about Real-Time Computing: A Serious Problem for Next Generation Systems, IEEE Computer, 21(10), pp. 10-19, October 1988.

Real-Time Computing The correctness of the system Logical result of the computation Functional correctness Time to produce the result Next generation RT system Distributed/adaptive Online guarantees Long lifetime 2017-04-17 Real-time computing

There is no science in RT system design Most good science grew out of attempts to solve practical problems Real-time system engineers need help The first flight of a space shuttle was delayed due to a subtle timing bug caused by a transient overload during system initialization A scientific framework to prevent such a bug to be included is needed Real-time scheduling, resource management, RT programming language, … 2017-04-17 Real-time computing

Advances in supercomputer hardware will cover RT requirements One can exploit parallel processors to improve throughput It does not mean timing constraints can be met automatically Unless HW is designed to perfectly match the application, the processors and their communication subsystems may not be able to handle all of the task load and time-critical traffic Real-time task and communication scheduling can get harder as more hardware is used 2017-04-17 Real-time computing

Demand for computational power often exceeds supply Intelligent management of finite resources is required 2017-04-17 Real-time computing

RT Computing = Fast Computing The objective of fast computing is to minimize the average response time The objective of real-time computing is to meet the individual timing requirement of each task Meet individual task deadlines Fast computing cannot necessarily provide predictability Fastest hardware & software used in the space shuttle failed to support the timing requirements Testing is not the answer 2017-04-17 Real-time computing

Worst case, not average case, response time matters Fast is relative Worst case, not average case, response time matters Not speed but predictability is the goal Functional and timing behaviors should be as deterministic as necessary to satisfy system specification Guarantee the delay is shorter than the upper bound Predictability is not only hardware or algorithmic issue The delay statement in Ada only specifies the minimum delay before the next task is scheduled Many things, including scheduling theory, software design, formal methods, RTOS, can change things 2017-04-17 Real-time computing

Hand-coding may have bugs, especially large RT program RT Programming = Assembly Coding, Priority Interrupt Programming, Device Driver Writing Hand-coding may have bugs, especially large RT program Objective in RT research Automate Customized resource scheduler from timing-constraint spec. 2017-04-17 Real-time computing

RT System Research = Performance Engineering Common misconceptions(5) RT System Research = Performance Engineering To investigate effective resource allocation strategies to satisfy timing-behavior requirement (≈Perf. Engineering) Specification & verification of timing behavior Programming language semantics Theoretical problems 2017-04-17 Real-time computing

Real-time systems function in static environment Not necessarily true Once deployed, real-time systems stay for more than 10 years Many embedded real-time systems these days need configurable, composable RTOS 2017-04-17 Real-time computing

Main Research Issues Specification and verification Modeling and verification of systems that are subject to timing constraints RT scheduling theory Meet the specified timing requirements Support the utilization bound to meet all deadlines Meet as many deadlines as possible, if it is impossible to meet all deadlines 2017-04-17 Real-time computing

Main Research Issues RTOS Guarantee RT constraint Support FT and distribution Scheduling time-constrained resource allocation RT programming language and design methodology High level abstraction to deal with complex real-time systems Management of time Schedulability check Reusable RT software module 2017-04-17 Real-time computing

Main Research Issues (Distributed) RTDB Fault tolerance Concurrency in transaction processing RT scheduling algorithm Fault tolerance Formal specification of the timing constraints Error handling RT system architecture Interconnection topology (process, I/O) Fast, reliable, and time-constrained communication Cost-effective and integrated fashion WCET analysis 2017-04-17 Real-time computing

Main Research Issues End-to-end deadlines Packet scheduling RT communication End-to-end deadlines Packet scheduling Dynamic routing Network buffer management Wireless Sensor Networks Newly emerging area Small, inexpensive, wireless sensors for RT sensing & control 2017-04-17 Real-time computing

Rate Monotonic, EDF (Earliest Deadline First), and Deadline Monotonic Scheduling Algorithms C. Liu and J. Layland, Scheduling Algorithm for Multiprogramming in a Hard Real-time Environment, Journal of the ACM, 20(1), pp. 41-61, January 1973. N.C. Audsley, A. Burns, M.F. Richardson, and A. J. Wellings, Hard real-time scheduling: The deadline monotonic approach, IEEE Workshop on Real-Time Operating Systems, 1992. N.C. Audsley, A. Burns, M.F. Richardson, and A. J. Wellings, Applying new scheduling theory to static priority preemptive scheduling, Software Engineering Journal, 8(5):284-292, Sept 1993. 2017-04-17 Real-time computing

Terminologies Job Task Release time Deadline Each unit of work that is scheduled and executed by the system Task A set of related jobs For example, a periodic task Ti consists of jobs J1, J2, J3, … coming at every period Release time Time instant at which a job becomes available for execution It can be executed at any time at or after the release time Deadline Time instant by which a job should be finished Relative deadline: Maximum allowable response time Absolute deadline = release time + relative deadline 2017-04-17 Real-time computing

Periodic task Ti Job Jik Deadline miss if Period Pi Worst case execution time Ci Relative deadline Di Job Jik Absolute deadline = release time + relative deadline Response time = finish time – release time Deadline miss if Finish time > absolute deadline Response time of Jik > Di 2017-04-17 Real-time computing

Optimal Scheduling Algorithm A scheduling algorithm S is optimal if S cannot schedule a real-time task set T, no other scheduling algorithm can schedule T E.g., Rate Monotonic & EDF 2017-04-17 Real-time computing

Assumptions Single processor Every task is periodic Deadline = period Tasks are independent WCET of each task is known Zero context switch time 2017-04-17 Real-time computing

Fixed Priority vs. Dynamic Priority Scheduling Algorithms Fixed priority system Assign the same priority to all the jobs in each task Rate monotonic Dynamic priority system Assign different priorities to the individual jobs in each task EDF 2017-04-17 Real-time computing

Rate Monotonic Optimal fixed priority scheduling algorithm Shorter period → Higher priority Higher rate → higher priority Utilization bound 2017-04-17 Real-time computing

RM Example t1 t2 t3 time Task Execution Time (C) End Of Period (T = Period Length) 2017-04-17 Real-time computing

Utilization Bound (UB) Test Ui = Ci Ti Processor Utilization for a task, i U(n) = n(2 - 1) 1 n Utilization Bound for n tasks Results: If U (=S Ui) ≤ U(n) then the set of tasks is schedulable. If U(n) < S Ui ≤ 1 then the test is inconclusive. U < U(n) is sufficient but not necessary 2017-04-17 Real-time computing

Utilization Bound Test Task Execution Time (C) Period (T) t1 40 100 t2 150 t3 350 U1 = 40 / 100 = 0.4 U(3) = 3(21/3 – 1) = 0.779 U2 = 40 / 150 = 0.267 Result: U1+2 = 0.667, schedulable. However, 0.779 < 0.953 < 1 Therefore, inconclusive for t3. U3 = 100 / 350 = 0.286 Utotal = 0.953 2017-04-17 Real-time computing

EDF Shorter absolute deadline → Higher priority Utilization bound Ub = 1 Ub is necessary and sufficient 2017-04-17 Real-time computing

Comparisons RMS RMS may not guarantee schedulability even when U < 1 Low overhead: Priorities do not change for a fixed task set EDF EDF guarantee schedulability as long as U <= 1 High overhead: Task priorities may change dynamically For more comparisons, refer to “Rate Monotonic vs. EDF: Judgment Day” 2017-04-17 Real-time computing

Assumptions Single processor Every task is periodic Relative deadline = period Tasks are independent WCET of each task is known Zero context switch time What happens if relative deadline < period? 2017-04-17 Real-time computing

Deadline Monotonic Scheduling Algorithm Shorter relative deadline → higher priority RMS is a special case of DMS where Di = Pi Necessary and sufficient schedulability analysis, called response time analysis, exists 2017-04-17 Real-time computing

Optimal Scheduling Algorithms Relative Deadline < Period DMS Shorter relative deadline → Higher priority Optimal preemptive fixed priority scheduling EDF Shorter absolute deadline → Higher priority Optimal preemptive dynamic priority scheduling 2017-04-17 Real-time computing

DMS Response Time Analysis Audsley et al. Tasks are sorted in non-increasing order of priority. (Ti has the highest priority) for (each task Ti) { I = 0; R=0; while (I + Cj > R) R = I + Ci; if (R > Di) return Unschedulable; I = ∑k=1, i-1 R/Pi Ci; } return Schedulable 2017-04-17 Real-time computing

Summary Di = Pi D < P Fixed Priority RMS Utilization bound Response time analysis DMS Dynamic Priority EDF Processor demand analysis Note: EDF is optimal for aperiodic tasks too 2017-04-17 Real-time computing