OSY Micro-Project
OSY Micro-Project
SUBMITTED TO M.S.B.T.E.,
Mumbai
2024-25
M.S.B.T.E.
Evolution sheet for Micro Project
Academic Year: - 2024-25 Name of Faculty: Mrs. V. S. Wangikar
Course: - Computer Engineering Course Code: - CO5I
Subject: - Operating System Subject Code: - 22516
Semester: - 5 Scheme: - I
Marks out of 4
Marks out of 6 for Total mars
for
performance in out of 10
Roll No Name of students performance in
group activity
oral/
Presentation
16 Tanishka Umesh Karande.
34 Samiksha Annasaheb Bhosale.
36 Swapnaja Samir Kumbhar.
62 Vaishnavi Santosh Chaudhari.
CERTIFICATE
is a bonafide work carried out by above students, under the guidance of Mrs. V. S. Wangikar and
it is submitted towards the fulfillment of requirement of MSBTE, Mumbai for the award of
Diploma in Computer Engineering at SVERI’s COE (Polytechnic), Pandharpur during the
academic year 2024-25.
(Mrs. V. S. Wangikar)
Guide
Place: Pandharpur.
Date: / /
Acknowledgement
3. Priority Scheduling :
It assigns each process a priority, and the CPU is allocated to the process with the highest priority. In its
preemptive form, it interrupts the current process if a higher-priority one arrives, but this can lead to
starvation for lower-priority tasks.
Advantages: Flexible as processes can have different priorities.
Disadvantages: Can cause starvation for lower-priority processes. Aging is a technique used to prevent
starvation by gradually increasing the priority of waiting processes.
Advantages: Fair allocation of CPU time to all processes. Good for time-sharing systems
.Disadvantages: Performance depends on the size of the time quantum. If too small, there’s too much
overhead; if too large, it behaves like FCFS.
6. Multiple-Level Queues :
It categorize processes into different queues based on attributes like priority or process type, with each
queue having its own scheduling algorithm. However, this can cause starvation for processes in lower-
priority queues if higher-priority queues are always busy.
Advantages: Separation of processes based on their priority and type.
Disadvantages: Hard to manage; processes may suffer from starvation if lower-priority queues are
neglected.
Introduction:
A Process Scheduler schedules different processes to be assigned to the CPU based on particular
scheduling algorithms. There are six popular process scheduling algorithms in which we can do study about
Round Robin Algorithm.
The Round robin scheduling algorithm is one of the CPU scheduling algorithms in which every process
gets a fixed amount of time quantum to execute the process.
In this algorithm, every process gets executed cyclically. This means that processes that have their burst
time remaining after the expiration of the time quantum are sent back to the ready state and wait for their
next turn to complete the execution until it terminates. This processing is done in FIFO order which
suggests that processes are executed on a first-come, first-serve basis.
Note: The CPU time quantum is the time period defined in the system.
First, the processes which are eligible to enter the ready queue enter the ready queue. After entering
the first process in Ready Queue is executed for a Time Quantum chunk of time. After execution is
complete, the process is removed from the ready queue. Even now the process requires some time to
complete its execution, and then the process is added to Ready Queue.
The Ready Queue does not hold processes which already present in the Ready Queue. The Ready Queue is
designed in such a manner that it does not hold non unique processes. By holding same processes
Redundancy of the processes increases.
Consider the above flow diagram for a better understanding of Round Robin scheduling algorithm:
After, the process execution is complete, the Ready Queue does not take the completed process for holding.
Example:-
Consider the four process p1,p2,p3,p4 with length of CPU burst time. Find out average waiting time and
average turnarround time for the Round Robin algorithm with time Slice 4 ms.
P1 8 0
P2 4 1
P3 9 2
P4 5 3
Ans :
P1 P2 P3 P4 P1 P3 P4 P3
0 4 8 12 16 20 24 25 26
Waiting time : P1 = 16-4 = 12-0 = 12
P2 = 4-1 = 3
P3 = 25-8 = 17-2 = 15
P4 = 24-4 = 20-3 = 17
12 + 3 + 15 + 17 47
4 4
Average Waiting time = 11.75ms
P2 = 8-1 = 7
P3 = 26-2 = 24
P4 = 25-3 = 22
20 + 7 + 24 + 22 73
=
4 4
int i = 0;
while (y != 0) {
if (temp[i] <= quant && temp[i] > 0) {
sum += temp[i];
temp[i] = 0;
count = 1;
} else if (temp[i] > 0) {
temp[i] -= quant;
sum += quant;
}
scanner.close();
}
}
Output:-
Advantages:
The Advantages of Round Robin CPU Scheduling are:
1. A fair amount of CPU is allocated to each job.
2. Because it doesn't depend on the burst time, it can truly be implemented in the system.
3. It is not affected by the convoy effect or the starvation problem as occurred in First Come First Serve
CPU Scheduling Algorithm.
Disadvantages:
The Disadvantages of Round Robin CPU Scheduling are:
1. Low Operating System slicing times will result in decreased CPU output.
2. Round Robin CPU Scheduling approach takes longer to swap contexts.
3. Time quantum has a significant impact on its performance.
4. The procedures cannot have priorities established.
Resources Used:-
Sr.
No. Specification Remark
As per
1 Intel Core i3/ i5, RAM 4GB
requirement
As per
2 Operating System – Windows 10
requirement
As per
3 Application – Microsoft Word 2010
requirement
Conclusion:
Round Robin process scheduling algorithm works on the principle of round-robin, where an equal share
of an object is given to each person in turns. Oldest, fairest, and easiest scheduling algorithms. It spends
a lot of time on context switching. Worst-case latency is the maximum time taken for the execution of
all the tasks in the OS.
1. The name of this algorithm comes from the round-robin principle, where every person gets an equal
share of something turn by turn.
2. Every process gets executed cyclically, and the processing is done in FIFO order.
3. The execution of the Round Robin scheduling algorithm mainly depends on the value of the time
quantum.
References:
https://www.javatpoint.com/round-robin-program-in-c
https://data-flair.training/blogs/round-robin-scheduling-algorithm/