Question: Recall that Shortest Remaining Time First (SRTF) is a variant of Shortest Job First (SJF) with preemption added in. Consider the following three processes for

Recall that Shortest Remaining Time First (SRTF) is a variant of Shortest Job First (SJF) with preemption added in. Consider the following three processes

for the CPU. The scheduler uses SRTF. The scheduler re-evaluates which process to run only upon the arrival of a new process into the

scheduling queue, or the completion of a process. The table shows the arrival time of each process.

Process

Arrival Time

Execution Time

P1

T0

5 ms

P2

T0 + 2 ms

4 ms

P3

T0 + 3 ms

1 ms

The scheduling starts at time T0.

Fill up the blank cell/cells in the table below with the appropriate time information.

(a) At time T0: (2 points)

Process

Remaining Time

P1

P2

Not Arrived Yet

P3

Not Arrived Yet

(b) At time T0 + 2 ms : (Process P2 arrives) (4 points)

Process

Remaining Time

P1

P2

P3

Not Arrived Yet

(c) At time T0 + 3 ms: (Process P3 arrives) (4 points)

Process

Remaining Time

P1

P2

P3

(d) Fill in the table below with the process that is executing on the processor during each time slot (the first slot has been filled up with Process P1). (10 points)

Interval T0 +

0 ms

1 ms

2 ms

3 ms

4 ms

5 ms

6 ms

7 ms

8 ms

9 ms

10 ms

11 ms

12 ms

Running Process

P1

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!