Introduction to RealTime Scheduling - PowerPoint PPT Presentation

1 / 17
About This Presentation
Title:

Introduction to RealTime Scheduling

Description:

Weighted Round Roben. Round Robin Scheduling - time-sharing systems ... Example algorithms: EDF, FIFO, LIFO etc. preemption versus non-preemption ... – PowerPoint PPT presentation

Number of Views:204
Avg rating:3.0/5.0
Slides: 18
Provided by: Fre58
Category:

less

Transcript and Presenter's Notes

Title: Introduction to RealTime Scheduling


1
Introduction to Real-Time Scheduling
  • Fred Kuhns
  • Applied Research Laboratory
  • Computer Science
  • Washington University

2
Introduction
  • Considerations
  • schedulability analysis performed
  • static or dynamic schedulability analysis
  • analysis result includes schedule
  • Scheduling Paradigms
  • static table-driven - static analysis and
    schedule
  • static priority driven - static analysis, no
    (explicit) schedule, priorities.
  • dynamic planning based - feasibility check at
    run-time, schedule produced
  • dynamic best effort - No feasibility check,
    attpemts to meet deadlines but no guarantee.

3
Scheduling Algorithms
  • Most instances, scheduling problem is intractable
  • Resource constrained scheduling is NP-complete.
    Precedence constraints agravate the problem.
  • Heuristics and approximation techniques used to
    handle tasks with complex requirements.

4
Static Table Driven
  • Typically applied to systems with safety critical
    requirements.
  • Resources preallocated to tasks
  • Periodic tasks feasible schedule if and only if
    there exists a feasible schedule for the
    Hyperperiod (least common multiple of the
    periods)
  • RM or EDF used for relatively simple systems
    (simple characteristics)

5
Priority-driven Preemptive
  • Most famous analysis of the problem is Liu and
    Layland where they described RM and EDF.
  • single processor, periodic tasks, preemption
  • RM static priorities based on period. Optimal
    among static-priority schemes.
  • EDF dynamic priority based on deadline.
  • May assign priority based on laxity - LLF Least
    Laxity First
  • May assign priority based on any of the tasks
    parameters

6
Priority Driven
  • Preemptive scheduling may simplify analysis but
    overhead needs to be considered.
  • scheduling algorithm
  • task dispatcher
  • context switch overhead

7
Dynamic Planning-based
  • Focus on dynamic feasibility checks
  • Must consider worst case execution times,
    resource requirements, timing constraints,
    periodic tasks, preemption, precedence
    constraints, importance levels and fault
    tolerance
  • If task arrival times are not known a priori,
    cannot guarantee performance
  • Various heuristic algorithms for scheduling tasks
    in a distributed environment.

8
Dynamic Best-Effort
  • Used by many systems system computes task
    priorities and schedules accordingly. Extensive
    simulations are used to gain confidence in
    behavior
  • May compensate for other priority driven
    algorithms (EDF and RM) which perform poorly in
    overload conditions
  • May use a value function to schedule during
    overload maximize sum of task values. May also
    discard low value tasks
  • Dynamic scheduling is optimal if it always
    produces a feasible schedule whenever a
    clairvoyant algorithm does.

9
Other Issues
  • Fault tolerance
  • static primary and alternate tasks.
  • static precomputed contingency schedules to
    speed recovery
  • fault-tolerance vs timeliness
  • Combine dynamic scheduling with imprecise
    computations to effect tradeoffs

10
Resource Reclaiming
  • Utilizing unused time variance in task execution
    time may result in unused time.
  • Run time anomalies when actual computation times
    of nonpreemptive tasks differ from expected
    causing unexpected behavior.
  • Resource reclamation algorithms can improve
    schedulability of dynamically arriving tasks.

11
RTOS
  • Primary function areas
  • Process management and synchronization
  • Memory management
  • Interprocess communication
  • I/O
  • Categories of RTOS
  • small proprietary
  • RT extensions to commercial timesharing systems
  • research operating systems

12
Small Proprietary OSes
  • Typically, kernel provides
  • fast context switch, small size, quick interrupt
    response time (predictable?), minimize interrupt
    disable times, memory partitions (no virtual
    memory, why?), special sequential files (why?)
  • Timing
  • bounded execution time of most primitives
  • real-time clock
  • priority scheduling mechanism
  • special alarms and timeout

13
RT Extensions to Commercial OSes
  • Advanced SW development environments
  • Problems
  • optimized for average case
  • assigns resources on demand
  • ignore application specific information
  • independent CPU scheduling and resource allcoation

14
Research Operating System
  • Develop extended or new process models
  • RT synchronization mechanisms
  • facilitate timing analysis
  • fault tolerance
  • multiprocessor or distributed support
  • real-time micro-kernel

15
Clock Driven
  • Scheduling time instants When scheduling
    decisions are made
  • clock-driven - instants predefined offline
  • table-driven - table precomputed offline

Scheduling time instants
16
Weighted Round Roben
  • Round Robin Scheduling - time-sharing systems
  • Weighted Round Robin associate weight with each
    job.
  • weight w number of time slices
  • adjusting weight allocates CPU shares

17
Priority Driven
  • Work-conserving The highest priority, runnable
    job is always dispatched to available CPU
  • resources are never idle while runnable jobs
  • Priority list, preemptions and other rules
    describe algorithm completly
  • Example algorithms EDF, FIFO, LIFO etc.
  • preemption versus non-preemption
Write a Comment
User Comments (0)
About PowerShow.com