You are on page 1of 3

COSC6384 Real-Time Systems

Assignment 1 (Spring 2005)

Question 1.
Suppose a task consists of n subtasks, Ji each of which has computation time Ci, i=1,...,n.
This task requests service at time T and has absolute deadline D. Summarize a formula to
compute the latest deadline for completing each subtask such that the deadline of the
entire task can be satisfied.

Question 2.
Determine whether you can feasibly schedule the following two task sets using the rate
monotonic algorithm. If yes show an RM schedule else check whether it is EDF
schedulable and give an EDF schedule. All tasks arrive at time 0.
(a).
TASK PERIOD COMPUTATION TIME

A 100 20
B 150 30
C 200 60
(b).
TASK PERIOD COMPUTATION TIME

A 50 8
B 20 3
C 35 15
D 10 2

Question 3.
The rate-monotonic scheduling algorithm is used to assign priority to the following task
set. All tasks arrive at time 0. Give an RM-schedule for the following task set.

TASK PERIOD COMPUTATION TIME

A 30 1
B 2 1
C 6 1
D 5 1
E 10 1

If the periods of the tasks in a task set are all multiples of a base unit, let's say 4, is the
static priority scheduler as good as the earliest deadline scheduler for this type of task
sets? Give a proof or show a counter example.

1
Question 4.
Give an EDF schedule for the following task set. All tasks arrive at time 0.

TASK PERIOD COMPUTATION TIME

A 24 2
B 36 3
C 5 2
D 14 2
E 4 1

Question 5.
Give an LLF schedule for the above task set in Question4.

Question 6.
Check whether the following task set is FIFO schedulable or not. If yes then give a FIFO
schedule.

TASK PERIOD COMPUTATION TIME ARRIVAL TIME

A 15 1 0
B 10 1 1
C 7 1 0
D 5 1 0
E 3 1 1

Question 7.
Given a task set which is rate monotonic schedulable, will the rate monotonic and earliest
deadline first schedule be the same or different? Justify your answer with examples.

Question 8.
Construct a task set that can be scheduled by the RM, EDF and LLF algorithms.

Question 9.
Construct a set of periodic tasks (showing start times, computation times, and periods)
which can be scheduled by the EDF algorithm but not by the RM algorithm.

Question 10.
Explain instances where the static and dynamic scheduler would be equivalent and when
they would differ. Which is more suitable for an operating system?

Question 11.
Prove that the utilization of any set of tasks must be less than or equal to 1 for a feasible
schedule (meeting all deadlines) to exist on a uniprocessor.

2
Question 12.
We have assumed in lectures that context-switching due to preemption incurs no
overhead. Now suppose context-switching (from one task to another) requires 'x' time
units. Consider a system with n tasks with computation times C1,C2,...,Cn and periods P1,
P2,...,Pn (which are equal to their deadlines and Pi < Pi+1). Derive the maximum value of
'x' for which this task set is EDF-schedulable. Show calculations steps.

Question 13.
A periodic process must be executed once in every period of the process. A system is
schedulable if all the processes can be scheduled as defined. Suppose our system has six
processes with periods 35, 60, 105, 200, 250, 300 msec each. These four processes
require 5, 12, 15, 30, 40 and 'x' msec of CPU time, respectively. What is the largest value
of 'x' for which the system is schedulable? Show calculations and the schedule.

Question 14.
Determine whether there is a feasible schedule for the following set of periodic processes.
If yes, show the schedule and the steps used to derive it.

T1: c11 = 2, c12 = 3, d1 = 7, p1 = 8


T2: c2 = 0.5, d2 = p2 = 16
T3: c3 = 0.5, d3 = p3 = 16
T4: c41 = 2, c41 = 3, d4 = p4 = 16

T1 must rendezvous with T4 after the first scheduling block of T1.


T4 must rendezvous T1 after first and second scheduling block of T4.

You might also like