Professional Documents
Culture Documents
Assignment 06
Assignment 06
Subject:- OS
Class /section:- CA
Non-Pre-Emptive:
Non-preemptive Scheduling is used when a process terminates, or a process switches from
running to the waiting state. In this scheduling, once the resources (CPU cycles) are allocated to
a process, the process holds the CPU till it gets terminated or reaches a waiting state. In the case
of non-preemptive scheduling does not interrupt a process running CPU in the middle of the
execution. Instead, it waits till the process completes its CPU burst time, and then it can allocate
the CPU to another process.
Round Robin:
In this algorithm, every process gets executed in a cyclic way. A certain time slice is defined in
the system which is called time quantum. Each process present in the ready queue is assigned
the CPU for that time quantum, if the execution of the process is completed during that time then
the process will terminate else the process will go back to the ready queue and waits for the
next turn to complete the execution.
P1 0 13 13 13 0 17
P2 1 5 18 17 13 24
P3 3 23 41 38 15 68
P4 4 3 44 40 37 33
P5 5 31 75 70 41 111
P6 6 3 78 72 69 77
P7 7 14 92 85 71 110
______________________THE END__________________________