1 / 75

Welcome!

Welcome!. PhD Dissertation Defense. PhD Candidate: Wenming Li Advisor: Dr. Krishna M. Kavi Committee: Dr. Krishna M. Kavi Dr. Robert Akl Dr. Phil Sweany. Group-EDF - A New Approach And An Efficient Non-Preemptive Algorithm for Soft Real-Time Systems. Contributions.

allyson
Download Presentation

Welcome!

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Welcome!

  2. PhD Dissertation Defense PhD Candidate: Wenming Li Advisor: Dr. Krishna M. Kavi Committee: Dr. Krishna M. Kavi Dr. Robert Akl Dr. Phil Sweany

  3. Group-EDF - A New Approach And An Efficient Non-Preemptive Algorithm for Soft Real-Time Systems

  4. Contributions • A new approach for soft real-time systems. • A new scheduling algorithm for soft real-time systems and soft Real-Time Operating System (RTOS).

  5. Contributions (Cont’d) • Our research work is a new approach for soft real-time systems. - First proposed the strategy of the dynamic grouping of tasks with deadlines. - First proposed a two-level scheduling scenario for real-time tasks.

  6. Contributions (Cont’d) • Group-EDF is a new scheduling algorithm for soft RTOS and real-time systems. - First proposed to use Earliest Deadline First (EDF) for dynamic groups and Shortest Job First (SJF) within a group.

  7. Focus • Soft real-time systems and soft RTOS. • Non-preemptive scheduling. • Real-time periodic, aperiodic, or sporadic tasks.

  8. The Taxonomy of Real-time Scheduling Our EDF/gEDF algorithm is applicable to the shaded region

  9. Terminology of the Real-Time Model

  10. Hard Real-Time Systems • Every resource management system must work in the correct order to meet time constraints. No deadline miss is allowed. • Disadvantage - Low utilization

  11. Soft Real-Time Systems • It is similar to hard real-time systems. But it is not necessary that every time constraint be met. Some deadline miss is tolerated. • Advantage - High utilization

  12. Non-Preemptive Scheduling • Why non-preemptive? - non-preemptive scheduling is more efficient than preemptive scheduling since preemption incurs context switching overhead which can be significant in fine-grained multithreading systems.

  13. Basic Real-Time Scheduling • First Come First Served (FCFS) • Round Robin (RR) • Shortest Job First (SJF)

  14. First Come First Served (FCFS) • Simple “first in first out” queue • Long average waiting time • Negative for I/O bound processes • Nonpreemptive

  15. Round Robin (RR) • FCFS + preemption with time quantum • Performance (average waiting time) is proportional to the size of the time quantum.

  16. Shortest Job First (SJF) • Optimal with respect to average waiting time. • Requires profiling of the execution times of tasks.

  17. Static Priority Scheduling – Rate-Monotonic (RM) • The shorter the period of a task, the higher is its priority (relative deadline = period). • A set of n independent, periodic jobs can be scheduled by the rate monotonic policy if e1/P1 + e2/P2 + … + en/Pnn (21/n - 1) - The upper bound on utilization is ln2 = 0.69 as n approaches infinity.

  18. Static Priority Scheduling – Deadline-Monotonic (DM) • The shorter the relative deadline of a task, the higher is its priority. • Suitable when relative deadline period • For arbitrary relative deadlines, DM outperforms RM in terms of utilization.

  19. Dynamic Priority Scheduling – Earliest Deadline First (EDF) • The first and the most effectively widely used dynamic priority-driven scheduling algorithm. • Effective for both preemptive and non-preemptive scheduling periodic, aperiodic, and sporadic tasks.

  20. Preemptive EDF • For a set of preemptive periodic, aperiodic, and sporadic tasks, EDF is optimal in the sense that EDF will find a schedule if a schedule is possible for other algorithms. - Approach 100% utilization for periodic tasks

  21. Non-Preemptive EDF • Optimal for sporadic non-preemptive tasks. • Scheduling periodic and aperiodic non-preemptive tasks is NP-hard. - Approach near optimal for non-preemptive scheduling on a uniprocessor system.

  22. Theory of EDF • Minimize maximum lateness Lmax = max {Li | i = 1, …, n} = max {Ci- di | i = 1, …, n} • The problem: 1 | nonpmtn | Lmax • Any sequence of jobs in nondecreasing order of due dates di, results in an optimal schedule. • The scheduling problem {1 | nonpmtn, ri | Lmax}is NP-hard. • Let Lmax = max {Ci- di | i = 1, …, n} = 0, that is, all deadlines of tasks must be met.

  23. POSIX 1003.1b • Portable Operating System Interface (POSIX) 1003.1b, the IEEE Computer Society’s Portable Application Standards Committee (PASC) - SCHED FIFO - SCHED RR - SCHED OTHER

  24. Related Work • Domino Effect of EDF - Overload • Overload Detection And Control - Best-effort by value-density V/C - Admission control - Disadvantage: Needing accurate utilization computing Switching between two scheduling schemes Using Worst Case Execution Time (WCET)

  25. Related Work • SCAN-EDF for disk scheduling - Use SJF to break deadline ties • Quantized deadlines (from CMU) - Static deadline windows

  26. Our Real-time Model • A task (job) in a real-time system or a thread in multithreading processing i is defined as: i = (ri, ei, Di, Pi)

  27. Overview of gEDF • Divide real-time jobs into groups by their deadlines, dynamically. • Groups are based on EDF but tasks within a group may be scheduled based on a different scheme - SJF, Value, Priority, etc. • gEDF is used both in underload and overload.

  28. Overview of gEDF (Cont’d) • We use SJF to enhance EDF, but it is extensible to other scheduling schemes. • gEDF is suitable for non-preemptive soft-real-time systems. • The criteria of selecting suitable grouping policy is flexible • Static deadline windows • Dynamic windows as jobs arrive

  29. Overview of gEDF (Cont’d) • A group in the gEDF algorithm depends on a group range parameter Gr. • A job j belongs to the same group as job i if didj (di + Gr*(di – t)), where t is the current time, 1 i, jN. We group jobs with deadlines that are very close to each other. - The jobs with very close deadlines are in a group (but not necessary if at the boundary of groups)

  30. The gEDF Algorithm • We assume a uniprocessor system. QgEDF is a queue for gEDF scheduling. The current time is represented by t. |QgEDF| represents the length of the queue QgEDF.  = (r, e, D, P) is the job at the head of the queue. - gEDF Group = {k | k QgEDF, dk – d1D1* Gr, 1 km, where m |QgEDF|}, and D1 is the deadline of the first job in a group

  31. The gEDF Algorithm (Cont’d) • Function Enqueue (QgEDF, ) if ( ’s deadline d > t ) then insert job  into QgEDF by Earliest Deadline First, i.e. di di+1di+2, where i, i+1,i+2 QgEDF, 1 i |QgEDF| - 2; end - Enqueue is invoked on job arrivals.

  32. The gEDF Algorithm (Cont’d) • Function Dequeue (QgEDF) if QgEDFthen find a job min with emin = min {ek | k QgEDF, dk – d1Gr*D1, 1 km, where m |QgEDF|}; run it and delete min from QgEDF; end - Dequeue is called when the processor becomes idle.

  33. The Experiment • Used MATLAB provided tools to generate tasks. - In each experiment generated N tasks. - The jobs are scheduling using EDF & gEDF. - The experiment is truncated at a predetermined time T. Success rate is computed based on m out of N jobs completed.

  34. The Experiment (Cont’d) • Varied - Load (or utilization) - Execution time - Deadline (tight deadlines & loose deadlines) - Group range - Deadline tolerance (hard vs. soft real-time)

  35. The Experiment (Cont’d) • For each set of parameters, the experiment is repeated 100 times and the results shown are the averages from the 100 experiments.

  36. Success Ratio: gEDF vs. EDFDeadline Tolerance Tr = 0.2

  37. Success Ratio: gEDF vs. EDFDeadline Tolerance Tr = 0.5

  38. Success Ratio: gEDF vs. EDFDeadline Tolerance Tr = 1.0

  39. Success Ratio: gEDF vs. EDFSummary of the three previous figures

  40. Success Ratio: gEDF vs. EDFSummary of the three previous figures • The gEDF algorithm obtains higher success ratio under higher system loads. • Suitable for soft real-time systems.

  41. Success Ratio: gEDF vs. EDF/Best-Effort/GuaranteeSummary when Tr = 0.5

  42. Effect of Deadline Laxity on Success RatioTight Deadline D = 1 (Deadline = Execution Time)and hard real-time

  43. Effect of Deadline Laxity on Success RatioTight Deadline D = 1 (Deadline = Execution Time)and softer real-time

  44. Effect of Deadline Laxity on Success RatioLoose Deadline D = 5 (Deadline = 5*Execution Time)

  45. Effect of Deadline Laxity on Success RatioLoose Deadline D = 5 (Deadline = 5*Execution Time)

  46. Effect of Deadline on Success RatioSuccess Ratio of EDF when D = 1, 2, 5, 10, and 15(i.e. Deadline = D*Execution Time)

  47. Effect of Deadline onSuccess RatioSuccess Ratio of gEDF when D = 1, 2, 5, 10, and 15(i.e. Deadline = D*Execution Time)

  48. Effect of Deadline onSuccess Ratio • The gEDF algorithm has higher performance (i.e. success ratio) than EDF with greater deadline laxity and greater deadline tolerances.

  49. Effect of Group Range (Gr)Gr = 0.1, 0.2, 0.5, 1.0, Tr = 0.1

  50. Effect of Group Range (Gr)Gr = 0.1, 0.2, 0.5, 1.0, Tr = 0.5

More Related