Question 3
[20 Marks]
Assuming the following five (5) processes P1, P2, P3, P4 and P5 are currently in the ready state with the Arrival time, burst times and priorities as shown in the table below.
\begin{tabular}{|l|c|c|c|}
\hline Process & Arrival time & Burst time (ms) & Priority \\
\hline
\end{tabular}
\( \nabla \) Edit with WPS Office
NOTE:
- Lower numbers represent higher priority and a \( 4 \mathrm{~ms} \) quantum time is given
Indicating the sequence and time the processes will be scheduled for execution, draw the Gantt chart for each of the following scheduling algorithms.
3.1 First Come First Serve
[3 Marks]
3.2 Shortest Job First (Non Pre-emptive)
[4 Marks]
3.3 Shortest Job First (Pre-emptive)
\( [4 \)
Marks]
3.4Priority (Pre-emptive)
[4 Marks]
3.5Round Robin
[5 Marks]
Question 4
[10 Marks]
Consider a multilevel feedback queue scheduling with three queues, numbered as Q1, Q2, and Q3. The scheduler first executes processes in Q1, which is given a time quantum of 2 milli-seconds. If a process does not finish within this time, it is moved to the tail of the Q2. The scheduler executes processes in \( \mathrm{Q} 2 \) only when \( \mathrm{Q} 1 \) is empty. The process at the head of the \( Q 2 \) is given a quantum of 4 milli-seconds. If it does not
\( \nabla \cdot \) Edit with WPS Office