Kai.
Vanjibaba Gramin Vikas Mandal’s
Sau. Shantidevi Chavan Institute of
Engineering & Technology(Polytechnic)
Bhoras, Dhule Road, Chalisgaon, Dist: Jalgaon(MS)
Department of Computer Engineering
A
PROJECT REPORT
ON
“SCHEDULING TYPES”
-Submitted To -
MAHARASHTRA STATE BOARD OF TECHNICAL EDUCATION
MUMBAI
For Academic Year
2024-2025
-Submitted By-
Mr.Vishal Vikas Kadve (Enrollment
No :2210040083)
1
Kai.Vanjibaba Gramin Vikas Mandal’s
Sau. Shantidevi Chavan Institute Of Engineering &
Technology (Polytechnic)
Bhoras, Dhule Road, Chalisgoan, Dist. Jalgaon (MS)
Department of Computer Engineering
CERTIFICATE
This is to certify that the entitled project
“SCHEDULING TYPES”
has been successfully completed by
Vishal Vikas Kadve
has been regularly accessed by us and that is well up to
the standard by
MAHARASHTRA STATE BOARD OF TECHNICAL
EDUCATION MUMBAI
For
Academic Year
2024-2025
Prof. M.V. Ahirrao Prof. N. B. Bagul
(GUIDE) (PRINCIPAL)
Prof. S. G. Ahirrao. Prof.
(HEAD OF DEPARTMENT) (EXAMINER)
2
Kai. Vanjibaba Gramin Vikas Mandal’s.
Sau. Shantidevi Chavan Institute of
Engineering & Technology (Polytechnic)
Bhoras, Dhule Road, chalisgoan, Dist. Jalgaon (MS)
Department of Computer Engineering
SUBMISSION
I am a student of Third year Computer
Engineering for the academic year 2024-
2025 humbly submit that I have completed
from time to time the project work on skills
and study as per the guidance of Prof. M. V.
Ahirrao.
The following project work have not
copied or it's any appreciable part from any
other in convenient of academic ethics.
Date: / /2024
Name of Student
Signature of Student
Mr.Vishal Vikas Kadve
3
ACKNOWLEDGEMENT
I would take this opportunity to express my sincere
thanks and gratitude to my teacher Prof.M.V.Ahirrao for her vital
support and guidance in completing this project.
I also express my gratitude to all the faculty members,
parents and my fellow mates who have helped me in making this
project a success. I also thank our almighty God for his blessings
showed on me during this period.
4
INDEX
SR.NO PAGE
. TOPIC NAME NO.
1 INTRODUCTION 7
2 SHEDULING TYPES 8
3 FIRST COME FIRST SERVE 9
SCHEDULING
4 SHORTEST JOB FIRST 12
SCHEDULING
5 ROUND- ROBIN SCHEDULING 13
6 PRIORITY SCHEDULING 15
7 CONCLUSION 16
8 REFERENCES 17
ABSTRACT
A scheduling discipline (also called scheduling
policy or scheduling algorithm) is an algorithm used for distributing
resources among parties which simultaneously and asynchronously
5
request them. Scheduling disciplines are used in routers (to handle
packet traffic) as well as in operating systems (to share CPU
time among both threads and processes), disk drives (I/O
scheduling), printers (print spooler), most embedded systems, etc.
The main purposes of scheduling algorithms are to
minimize resource starvation and to ensure fairness amongst the
parties utilizing the resources. Scheduling deals with the problem of
deciding which of the outstanding requests is to be allocated
resources. There are many different scheduling algorithms. In this
section, we introduce several of them.In packet-switched computer
networks and other statistical multiplexing, the notion of
a scheduling algorithm is used as an alternative to first-come first-
served queuing of data packets.
INTRODUCTION
Scheduling is the process of arranging, controlling and
optimizing work and workloads in a production process or
manufacturing process. In manufacturing, the purpose is to minimize
6
the production time and costs, by telling a production facility when
to make, with which staff, and on which equipment.
In real-time environments, such as embedded
systems for automatic control in industry (for example robotics), the
scheduler also must ensure that processes can meet deadlines; this is
crucial for keeping the system stable.
In general, most processes can be described as either I/O-
bound or CPU-bound. An I/O-bound process is one that spends more
of its time doing I/O than it spends doing computations. A
CPU(Central Processing Unit)-bound process, in contrast, generates
I/O requests infrequently, using more of its time doing
computations. It is important that a long-term scheduler selects a
good process mix of I/O-bound and CPU-bound processes.
SCHEDULING TYPES
Scheduling is a method that is used to distribute valuable
computing resources, usually processor time, bandwidth and
7
memory, to the various processes, threads, data flows and
applications that need them. Scheduling is done to balance the load
on the system and ensure equal distribution of resources and give
some prioritization according to set rules. This ensures that a
computer system is able to serve all requests and achieve a certain
quality of service.
Following are the types of CPU Scheduling:
1. First Come First Serve Scheduling
2. Shortest Job First Scheduling
3. Round- Robin Scheduling
4. Priority Scheduling
FIRST COME FIRST SERVE
SCHEDULING
First Come First Serve CPU Scheduling Algorithm shortly
8
known as FCFS is the first algorithm of CPU Process Scheduling
Algorithm. In First Come First Serve Algorithm what we do is to allow
the process to execute in linear manner.This means that whichever
process enters process enters the ready queue first is executed first.
This shows that First Come First Serve Algorithm follows First In First
Out (FIFO) principle.
The First Come First Serve Algorithm can be executed in Pre
Emptive and Non Pre Emptive manner. Before, going into examples,
let us understand what is Pre Emptive and Non Pre Emptive
Approach in CPU Process Scheduling.
Pre Emptive Approach:
In this instance of Pre Emptive Process Scheduling, the OS allots the
resources to a Process for a predetermined period of time. The
process transitions from running state to ready state or from waiting
state to ready state during resource allocation. This switching
happens because the CPU may assign other processes precedence
and substitute the currently active process for the higher priority
process.
Non Pre Emptive Approach:
In this case of Non Pre Emptive Process Scheduling, the resource
cannot be withdrawn from a process before the process has finished
running. When a running process finishes and transitions to the
waiting state, resources are switched.
EXAMPLE
S. No Process ID Process Name Arrival Time Burst Time
9
___ ______ _______ _______ _______
1 P1 A 0 9
2 P2 B 1 3
3 P3 C 1 2
4 P4 D 1 4
5 P5 E 2 3
6 P6 F 3 2
Now, let us solve this problem with the help of the Scheduling
Algorithm named First Come First Serve in a Non Preemptive
Approach.
Gantt chart for the above Example 1 is:
Turn Around Time = Completion Time - Arrival Time
Waiting Time = Turn Around Time - Burst Time
Solution to the Above Example
The Average Completion Time is:
Average CT = ( 9 + 12 + 14 + 18 + 21 + 23 ) / 6
Average CT = 97 / 6
Average CT = 16.16667
The Average Waiting Time is:
Average WT = ( 0 + 8 + 11 + 13 + 16 + 18 ) /6
10
Average WT = 66 / 6
Average WT = 11
The Average Turn Around Time is:
Average TAT = ( 9 + 11 + 13 + 17 + 19 +20 ) / 6
Average TAT = 89 / 6
Average TAT = 14.83334
This is how the FCFS is solved in Non Pre Emptive Approach.
SHORTEST JOB FIRST SCHEDULING
11
In SJF scheduling, the process with the lowest burst time,
among the list of available processes in the ready queue, is going to
be scheduled next.
However, it is very difficult to predict the burst time needed for
a process hence this algorithm is very difficult to implement in the
system.
Advantages of SJF
1. Maximum throughput
2.Minimum average waiting and turnaround time
Disadvantages of SJF
1.May suffer with the problem of starvation
2.It is not implementable because the exact Burst time for a process
can't be known in advance.
ROUND-ROBIN SCHEDULING
12
Round Robin CPU Scheduling is the most important CPU
Scheduling Algorithm which is ever used in the history of CPU
Scheduling Algorithms. Round Robin CPU Scheduling uses Time
Quantum (TQ). The Time Quantum is something which is removed
from the Burst Time and lets the chunk of process to be completed.
Time Sharing is the main emphasis of the algorithm. Each step of this
algorithm is carried out cyclically. The system defines a specific time
slice, known as a time quantum.
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,
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.
After, the process execution is complete, the Ready Queue does not
take the completed process for holding.
Advantages of Round- Robin
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 .
13
Disadvantages of Round-Robin
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.
14
PRIORITY SCHEDULING
In Priority scheduling, there is a priority number
assigned to each process. In some systems, the lower the number,
the higher the priority. While, in the others, the higher the number,
the higher will be the priority.
The Process with the higher priority among the
available processes is given the CPU. There are two types of priority
scheduling algorithm exists. One is Preemptive priority scheduling
while the other is Non Preemptive Priority scheduling.
The priority number assigned to each of the process may or
may not vary. If the priority number doesn't change itself throughout
the process, it is called static priority, while if it keeps changing itself
at the regular intervals, it is called dynamic priority.
15
CONCLUSION
Scheduling is important in many different computer
environments. One of the most important areas is scheduling which
programs will work on the CPU. This task is handled by the Operating
System (OS) of the computer and there are many different ways in
which we can choose to configure programs.
Process Scheduling allows the OS to allocate CPU time
for each process. Another important reason to use a process
scheduling system is that it keeps the CPU busy at all times. This
allows you to get less response time for programs.
16
REFERENCE
https://www.geeksforgeeks.org/cpu-scheduling-in-
operating-systems/
https://www.guru99.com/shortest-job-first-sjf-
scheduling.html
https://www.javatpoint.com/os-round-robin-scheduling-
algorithm
https://www.guru99.com/priority-scheduling-program.html
17