A Priority Based Round Robin Cpu Scheduling Algorithm For Real Time Systems
A Priority Based Round Robin Cpu Scheduling Algorithm For Real Time Systems
Submitted to:
Ms. Meenakshi Srivastava
Submitted by:
Aayush Singh 2K20/IT/03
Abhinav Tripathi 2K20/IT/05
Abstract
The main objective is to develop a new approach for Round Robin CPU scheduling algorithm
which improves the performance of CPU in real time operating system.
The proposed Priority based Round-Robin CPU Scheduling algorithm is based on the
integration of Round Robin and Priority Scheduling algorithm. It retains the advantage of
Round Robin in reducing starvation and also integrates the advantage of priority scheduling.
The proposed algorithm also implements the concept of aging by assigning new priorities to
the processes.
The proposed algorithm improves all the drawbacks of Round Robin CPU scheduling
algorithm.
We have also done a comparative analysis of proposed algorithm with existing Round Robin
scheduling algorithm on the basis of varying time quantum, average waiting time, average
turnaround time and number of context switches.
Introduction
Scheduling is the process by which processes are given access to system resources. CPU
scheduling plays an important role in the real-time operating system which always has a
time constraint on computations.
A real-time system is one whose applications are mission-critical, where real-time tasks
should be scheduled to be completed before their deadlines. In Real-time systems, each
task should be invoked after the ready time and must be completed before its deadline.
Simple round robin architecture is not suitable to implement in Soft real-time systems
due to more number of context switches, and longer waiting and response times. This in
turn leads to low throughput in the system. If a real-time process has a relatively larger
CPU burst it will lead to the problem of starvation.
Priority scheduling may be a better option for real-time scheduling but it will face a similar
problem i.e. low priority processes will always be starved.
Scheduling Objectives
There are a variety of factors that must be considered while designing a scheduling
algorithm:-
Maximize throughput
Avoid indefinite blocking or starvation
Minimize overhead
Enforcement of priorities
Achieve balance between response and utilization
Round Robin Algorithm
Round Robin is a CPU scheduling algorithm where each process is assigned a fixed time slot in a
cyclic way. It is simple, easy to implement, and starvation-free as all processes get fair share of
CPU.
With these observations it was found that the existing simple round robin architecture is not
suitable for real time systems. So, its drawbacks are eliminated in the proposed modified version
of round robin.
Priority Scheduling Algorithm
Disadvantages:-
Starvation of lower priority processes is possible if large number of higher priority processes
keep arriving continuously.
Proposed Algorithm
The proposed architecture focuses on the drawbacks of simple round robin architecture which gives equal
priority to all the processes. The proposed architecture eliminates the defects of implementing simple round
robin architecture. The algorithm will be executed in two steps which will help to minimize a number of
performance parameters such as context switches, average waiting time and average turnaround time.
Here we have considered a set of five processes A, B, C, D and E with given CPU burst time and
associated priorities.
Time quantum is 5 ms.
According to Simple RR Scheduling
Gantt Chart:-
Gantt Chart:-
References
20Priority%20based.pdf
https://www.tutorialspoint.com/operating_system/os_process_sch
eduling_algorithms.htm#:~:text=Priority%20scheduling%20is%20a%2
0non,first%20come%20first%20served%20basis.
https://www.guru99.com/round-robin-scheduling-example.html
Thank-you!