Docsity

Gantt Chart - Computer Architecture and Operating System - Homework | ECE 3055, Assignments of Electrical and Electronics Engineering

Toggle sidebar
bg1
Score_N/A_ Section___N/A___ Name:____ KEY โ€“ DR_________________
ECE 3055 Homework - Due Date: Wednesday, April 10
The following processes arrive for execution at the times indicated. Use preemptive scheduling for SRTF
and RR and base all decisions on the information you have at the time the decision is made. At arrival time,
the burst execution time is known and the process is already in the ready queue.
Process Arrival Time CPU Burst or Execution Time
P1 0.0ms 6ms
P2 1.0ms 3ms
P3 3.0ms 2ms
Draw a Gantt chart using FCFS: (1.5 pts)
________________________________________________________________________________
| P1 | P2 | P3 |
|___________________________________________|_____________________|_______________|
01234567891011
Draw a Gantt chart using SJF (no preemption): (1.5 pts)
________________________________________________________________________________
| P1 | P3 | P2 |
|___________________________________________|______________|______________________|
01234567891011
Draw a Gantt chart using SRTF: (1.5 pts)
________________________________________________________________________________
| P1 | P2 | P2 | P3 | P1 |
|_______|______________|_______|______________|____________________________________|
01234567891011
Draw a Gantt chart using RR with time slice =2: (1.5 pts โ€“ Two possibilities)
_________________________________________________________________________________
| P1 | P2 | P3 | P1 | P2 | P1 |
|_______________|______________|______________|______________|_______|______________|
| P1 | P2 | P1 | P3 | P2 | P1 |
|_______________|______________|______________|______________|_______|______________|
01234567891011
Average Turnaround Time Average Wait Time
(0.5 pts each)
FCFS ___ 22/3 __ (7.33) __ ___ 11/3 __ (3.67) ___
SJF ___ 21/3 __ (7.00) __ ___ 10/3 __ (3.33) ___
SRTF ___ 17/3 __ (5.67) __ _________ (2.00) ___
RR ___ 22/3 __ (7.33) __ ___ 11/3 __ (3.67) ___
___ 13/3 __ (4.33) ___

Partial preview of the text

Download Gantt Chart - Computer Architecture and Operating System - Homework | ECE 3055 and more Assignments Electrical and Electronics Engineering in PDF only on Docsity!

Score_N/A_ Section___N/A___ Name:____KEY โ€“ DR_________________

ECE 3055 Homework - Due Date: Wednesday, April 10

The following processes arrive for execution at the times indicated. Use preemptive scheduling for SRTF and RR and base all decisions on the information you have at the time the decision is made. At arrival time, the burst execution time is known and the process is already in the ready queue. Process Arrival Time CPU Burst or Execution Time P1 0.0ms 6ms P2 1.0ms 3ms P3 3.0ms 2ms Draw a Gantt chart using FCFS: (1.5 pts)


| P1 | P2 | P3 | |___________________________________________|_____________________|_______________| 0 1 2 3 4 5 6 7 8 9 10 11 Draw a Gantt chart using SJF (no preemption): (1.5 pts)


| P1 | P3 | P2 | |___________________________________________|______________|______________________| 0 1 2 3 4 5 6 7 8 9 10 11 Draw a Gantt chart using SRTF: (1.5 pts)


| P1 | P2 | P2 | P3 | P1 | |_______|______________|_______|______________|____________________________________| 0 1 2 3 4 5 6 7 8 9 10 11 Draw a Gantt chart using RR with time slice =2: (1.5 pts โ€“ Two possibilities)


| P1 | P2 | P3 | P1 | P2 | P1 | |_______________|______________|______________|______________|_______|______________| | P1 | P2 | P1 | P3 | P2 | P1 | |_______________|______________|______________|______________|_______|______________| 0 1 2 3 4 5 6 7 8 9 10 11

Average Turnaround Time Average Wait Time

(0.5 pts each)

FCFS 22/3(7.33)_ 11/3(3.67)__

SJF 21/3(7.00)_ 10/3(3.33)__

SRTF 17/3(5.67)_ _________(2.00)___

RR 22/3(7.33)_ 11/3(3.67)__

13/3(4.33)__