SlideShare a Scribd company logo
6
Most read
18
Most read
19
Most read
CHAPTER 7
CPU SCHEDULING: BASIC CONCEPTS, SCHEDULING CRITERIA,
SCHEDULING ALGORITHMS, ALGORITHM EVALUATION
CPU SCHEDULING CRITERIA
• Definition: CPU scheduling is a crucial part of operating systems that determines the order and priority of processes to
run on a CPU at any given moment.
• Purpose: It allows multiple processes to run concurrently on the same processor, optimizing system performance.
• Functionality: The CPU scheduler allocates CPU time to processes based on parameters like CPU usage, throughput,
turnaround, waiting time, and response time.
• Importance: Ensures correct and timely execution of processes, contributing to overall system efficiency.
• Algorithms: Different CPU scheduling algorithms exist, each with distinct properties. The choice of algorithm depends
on factors such as system requirements and priorities.
• Criteria for Comparison: Various criteria, including CPU usage, throughput, turnaround time, waiting time, and
response time, are used to compare and evaluate the effectiveness of CPU scheduling algorithms.
CPU Scheduling in Operating Systems
• Objective: CPU scheduling aims to complete work on time by efficiently utilizing the CPU, allowing one process to use
it while others are in standby due to resource unavailability.
• Resource Utilization: CPU scheduling ensures optimal use of the CPU by allowing processes to run when others are
delayed, such as waiting for I/O resources.
• System Improvement: The purpose is to enhance system efficiency, speed, and fairness, ensuring that processes are
executed in a timely and equitable manner.
• Idle CPU Handling: When the CPU is idle, the operating system's temporary scheduler selects a process from the ready
queue, which contains processes prepared for execution.
• Launching Processes: The selected process is assigned the CPU for execution, ensuring a continuous flow of tasks and
preventing unnecessary CPU downtime.
• Temporary Scheduler: The temporary scheduler plays a crucial role in selecting processes for execution, managing the
flow of tasks when the CPU becomes available.
States of a Process in Operating Systems
States of a Process in Operating Systems
• New (Create):
• Process is about to be created but not yet created.
• Program in secondary memory picked up by OS to create the process.
• Ready:
• Follows the "New" state.
• Process is loaded into main memory.
• Ready to run and waiting for CPU time.
• Maintained in a queue called the ready queue.
• Run:
• Process chosen from ready queue for execution.
• Instructions within the process are executed by a CPU core.
• Blocked or Wait:
• Occurs when process requests I/O, user input, or access to a critical region.
• Process enters a waiting state, not requiring CPU.
• Resumes to the ready state once I/O or critical region access is complete.
States of a Process in Operating Systems
• Terminated or Completed:
• Process is killed, and PCB (Process Control Block) is deleted.
• Resources allocated to the process are released or deallocated.
• Suspend Ready:
• Process initially in ready state but swapped out of main memory.
• Placed onto external storage by the scheduler.
• Transitions back to ready state when brought back to main memory.
• Suspend Wait or Suspend Blocked:
• Similar to Suspend Ready but involves processes performing I/O operations.
• Lack of main memory causes them to move to secondary memory.
• Transitions back to Suspend Ready after completing the task.
• CPU and I/O Bound Processes:
• CPU Bound Process: Intensive in CPU operations.
• I/O Bound Process: Intensive in I/O operations.
How does a process move between different states in an
operating system?
A process can move between different states in an operating system based on its execution
status and resource availability.
• New to Ready:
• Process is created and in the new state.
• Moves to the ready state when the operating system allocates necessary
resources.
• Ready to Running:
• CPU becomes available.
• Operating system selects a process from the ready queue based on
scheduling algorithms.
• Process moves to the running state for execution.
• Running to Blocked:
• Process needs to wait for an event (e.g., I/O operation or system call).
• Moves to the blocked state until the required event occurs.
How does a process move between different states in an
operating system?
A process can move between different states in an operating system based on its execution
status and resource availability.
• Running to Ready:
• Running process is preempted by the operating system.
• Moves to the ready state, often due to a higher-priority process becoming
ready.
• Blocked to Ready:
• Event a blocked process was waiting for occurs.
• Process moves to the ready state, ready for execution.
• Running to Terminated:
• Process completes execution or is terminated by the operating system.
• Moves to the terminated state.
Type of Scheduler in Operating Systems
Types of Schedulers – Short, Middle & Long Term
• Long-term Scheduler (Job Scheduler):
• Objective: Determines how many processes should stay in the ready
state, deciding the degree of multiprogramming.
• Frequency: Runs infrequently, as its decisions last for a long time.
• Impact: Influences overall system performance by controlling the
number of processes in the ready state.
Types of Schedulers - Short, Middle & Long Term
• Short-term Scheduler (CPU Scheduler):
• Objective: Decides which process to execute next and initiates context
switching.
• Dispatcher: Utilizes a dispatcher (software) to move processes between
ready and running states.
• Frequency: Runs frequently, managing the immediate execution of
processes.
• Alias: Also known as the CPU scheduler.
Types of Schedulers - Short, Middle & Long Term
• Middle-term Scheduler:
• Objective: Makes decisions regarding process suspension, especially for
swapping between main memory and secondary storage.
• Swapping: Involves moving processes to and from main memory to
optimize resource usage.
• Frequency: Runs when needed, typically to manage the degree of
multiprogramming.
• Impact: Affects system performance by regulating the presence of
processes in main memory.
Multiprogramming
• Preemption – Process is forcefully removed from CPU.
Pre-emotion is also called time sharing or multitasking.
• Non-preemption – Processes are not removed until they
complete the execution. Once control is given to the CPU for a
process execution, till the CPU releases the control by itself,
control cannot be taken back forcibly from the CPU.
Operation on the Process
• 1. Creation: The process will be ready once it has been created, enter the ready queue (main
memory), and be prepared for execution.
• 2. Planning: The operating system picks one process to begin executing from among the
numerous processes that are currently in the ready queue. Scheduling is the process of
choosing the next process to run.
• 3. Application: The processor begins running the process as soon as it is scheduled to run.
During execution, a process may become blocked or wait, at which point the processor
switches to executing the other processes.
• 4. Killing or Deletion: The OS will terminate the process once its purpose has been fulfilled.
The process’s context will be over there.
Multiple Choice Questions
1. What is the purpose of the Long-term Scheduler in an operating system?
• A) Decides process execution order
• B) Manages context switching
• C) Determines degree of multiprogramming
• D) Handles I/O operations
2. Which scheduler runs infrequently and influences the overall system performance?
• A) Short-term Scheduler
• B) Long-term Scheduler
• C) Medium-term Scheduler
• D) CPU Scheduler
Multiple Choice Questions
3. What does the Short-term Scheduler (CPU Scheduler) primarily decide?
• A) Degree of multiprogramming
• B) Process suspension
• C) Process execution order
• D) Swapping decisions
4. What is the primary function of the Medium-term Scheduler?
• A) Determines degree of multiprogramming
• B) Manages context switching
• C) Makes decisions about process suspension and swapping
• D) Allocates CPU time
Multiple Choice Questions
5. When does a process move from the Ready to Running state in the context of scheduling?
• A) When it completes execution
• B) When the CPU becomes available
• C) When it needs to wait for an event
• D) When a higher-priority process becomes ready
6. What is the primary purpose of context switching in an operating system?
• A) Allocating CPU time to processes
• B) Saving and restoring the CPU state for process switching
• C) Making decisions about process suspension
• D) Determining the degree of multiprogramming
Multiple Choice Questions
7. In which state does a process wait for an event, such as I/O operation or user input?
• A) Ready
• B) Blocked or Wait
• C) Running
• D) Terminated
8. When does a process move from the Running to the Ready state?
• A) When it completes execution
• B) When it needs to wait for an event
• C) When preempted by the operating system
• D) When the CPU becomes available
Multiple Choice Questions
9. What is the role of the dispatcher in the context of scheduling?
• A) Determines degree of multiprogramming
• B) Manages context switching
• C) Allocates CPU time to processes
• D) Makes decisions about process suspension
10. What does the term "CPU Bound Process" refer to?
• A) Intensive in I/O operations
• B) Intensive in CPU operations
• C) Ready for execution
• D) Completed its execution

More Related Content

PPTX
Operating System
GowriLatha1
 
PDF
Process And Scheduling Algorithms in os
Guna Dhondwad
 
PPTX
Module- Operating Systems presentation Two
adityaduggi0
 
PDF
processscheduler-150319224416-conversion-gate01.pdf
jayswalkhushi32
 
PPTX
Process scheduling
Deepika Balichwal
 
PDF
Process management- This ppt contains all required information regarding oper...
ApurvaLaddha
 
PPTX
Unit 2_OS process management
JayeshGadhave1
 
PPTX
Process scheduling
V.V.Vanniaperumal College for Women
 
Operating System
GowriLatha1
 
Process And Scheduling Algorithms in os
Guna Dhondwad
 
Module- Operating Systems presentation Two
adityaduggi0
 
processscheduler-150319224416-conversion-gate01.pdf
jayswalkhushi32
 
Process scheduling
Deepika Balichwal
 
Process management- This ppt contains all required information regarding oper...
ApurvaLaddha
 
Unit 2_OS process management
JayeshGadhave1
 

Similar to CPU Scheduling Criteria CPU Scheduling Criteria (1).pptx (20)

PPTX
Unit 1 process management operating system.pptx
eswarbongu67
 
PDF
Operating System-Concepts of Process
Shipra Swati
 
PPTX
Lecture 4 process cpu scheduling
Kumbirai Junior Muzavazi
 
PPTX
Process Management of Operating Systems.
hostnameharsh
 
PPTX
Os unit 3 , process management
Arnav Chowdhury
 
PPTX
Operating System.pptx
VanshikaRajput33
 
PDF
OS - Process Concepts
Mukesh Chinta
 
PDF
seminar report
Nakul Sharma
 
PDF
OS-Process.pdf
Rakibul Rakib
 
PDF
UNIT - 3 PPT(Part- 1)_.pdf
AyushSharma651966
 
PPT
Operating System
Subhasis Dash
 
PPTX
52bf066dbfcc4d739fa99d255dba287a.pptx
11SnehlataGujar
 
PPTX
Operating System Process Management.pptx
minaltmv
 
PPTX
Lecture 4 - Process Scheduling.pptx
Amanuelmergia
 
DOCX
Process scheduling
lodhran-hayat
 
PPTX
Operating system 28 fundamental of scheduling
Vaibhav Khanna
 
PPTX
Lecture 4 - Process Scheduling (1).pptx
Amanuelmergia
 
PDF
Module 3-cpu-scheduling
Hesham Elmasry
 
PPTX
RDos.pptx
RRamyaDevi
 
PPTX
THE BASIC CONCEPTS OF PROCESSING MANAGEMENT chapter 2.pptx
natyesu
 
Unit 1 process management operating system.pptx
eswarbongu67
 
Operating System-Concepts of Process
Shipra Swati
 
Lecture 4 process cpu scheduling
Kumbirai Junior Muzavazi
 
Process Management of Operating Systems.
hostnameharsh
 
Os unit 3 , process management
Arnav Chowdhury
 
Operating System.pptx
VanshikaRajput33
 
OS - Process Concepts
Mukesh Chinta
 
seminar report
Nakul Sharma
 
OS-Process.pdf
Rakibul Rakib
 
UNIT - 3 PPT(Part- 1)_.pdf
AyushSharma651966
 
Operating System
Subhasis Dash
 
52bf066dbfcc4d739fa99d255dba287a.pptx
11SnehlataGujar
 
Operating System Process Management.pptx
minaltmv
 
Lecture 4 - Process Scheduling.pptx
Amanuelmergia
 
Process scheduling
lodhran-hayat
 
Operating system 28 fundamental of scheduling
Vaibhav Khanna
 
Lecture 4 - Process Scheduling (1).pptx
Amanuelmergia
 
Module 3-cpu-scheduling
Hesham Elmasry
 
RDos.pptx
RRamyaDevi
 
THE BASIC CONCEPTS OF PROCESSING MANAGEMENT chapter 2.pptx
natyesu
 
Ad

More from TSha7 (20)

PPTX
Computer_Graphics_Presentationa (1).pptx
TSha7
 
PPTX
Guidelines and Examples.pptxGuidelines and Examples.pptx
TSha7
 
PPTX
01-introduction-130924015121-phpapp02.pptx
TSha7
 
PPTX
Core-Challenges-in-Supply-Chain-for-Minimising-Operational-Waste-in-the-Manuf...
TSha7
 
PPTX
Computer-Graphics Fundamentals of Computer Graphics
TSha7
 
PPTX
Fundamentalsss-of-Computer-Graphics.pptx
TSha7
 
PPTX
electronicpaymentppt-140601022736-phpapp02.pptx
TSha7
 
PPT
5-170401094214-1704010942145-170401094214.ppt
TSha7
 
PDF
operating system in computer science .pdf
TSha7
 
PDF
operating system in computer science ch05.pdf
TSha7
 
PPTX
nursing researvh RESEARCH PROPOSAL SLIDE.pptx
TSha7
 
PPTX
Streamlining Collaboration and Development - cloud computing .pptx
TSha7
 
PPTX
CHAPTER 7 Legal Issues in E-Commerce: A Beginner's Guide
TSha7
 
PPTX
CHAPTER 3 oop with programming java language
TSha7
 
PPTX
CHAPTER 5 oop chapter 5 programming sem2
TSha7
 
PPTX
CHAPTER 6 oop with c++ chapter programming
TSha7
 
PDF
introduction to Python and Computer Programming.pdf
TSha7
 
PDF
Lect 1b - Introduction to Pharmacy Informatics 1b.pdf
TSha7
 
PDF
Lect 1a - Introduction to Pharmacy Informatics 1a.pdf
TSha7
 
PPTX
APznzabZBYmM9xNVBHfOxhzhAYK6CVARVaOcFQRGQ_SDH3ZHiu4lPbmPUi4L1H3zAkRth3WEwZR2u...
TSha7
 
Computer_Graphics_Presentationa (1).pptx
TSha7
 
Guidelines and Examples.pptxGuidelines and Examples.pptx
TSha7
 
01-introduction-130924015121-phpapp02.pptx
TSha7
 
Core-Challenges-in-Supply-Chain-for-Minimising-Operational-Waste-in-the-Manuf...
TSha7
 
Computer-Graphics Fundamentals of Computer Graphics
TSha7
 
Fundamentalsss-of-Computer-Graphics.pptx
TSha7
 
electronicpaymentppt-140601022736-phpapp02.pptx
TSha7
 
5-170401094214-1704010942145-170401094214.ppt
TSha7
 
operating system in computer science .pdf
TSha7
 
operating system in computer science ch05.pdf
TSha7
 
nursing researvh RESEARCH PROPOSAL SLIDE.pptx
TSha7
 
Streamlining Collaboration and Development - cloud computing .pptx
TSha7
 
CHAPTER 7 Legal Issues in E-Commerce: A Beginner's Guide
TSha7
 
CHAPTER 3 oop with programming java language
TSha7
 
CHAPTER 5 oop chapter 5 programming sem2
TSha7
 
CHAPTER 6 oop with c++ chapter programming
TSha7
 
introduction to Python and Computer Programming.pdf
TSha7
 
Lect 1b - Introduction to Pharmacy Informatics 1b.pdf
TSha7
 
Lect 1a - Introduction to Pharmacy Informatics 1a.pdf
TSha7
 
APznzabZBYmM9xNVBHfOxhzhAYK6CVARVaOcFQRGQ_SDH3ZHiu4lPbmPUi4L1H3zAkRth3WEwZR2u...
TSha7
 
Ad

Recently uploaded (20)

PDF
The-Invisible-Living-World-Beyond-Our-Naked-Eye chapter 2.pdf/8th science cur...
Sandeep Swamy
 
PPTX
Python-Application-in-Drug-Design by R D Jawarkar.pptx
Rahul Jawarkar
 
PPTX
Measures_of_location_-_Averages_and__percentiles_by_DR SURYA K.pptx
Surya Ganesh
 
PPTX
A Smarter Way to Think About Choosing a College
Cyndy McDonald
 
DOCX
SAROCES Action-Plan FOR ARAL PROGRAM IN DEPED
Levenmartlacuna1
 
PPTX
An introduction to Prepositions for beginners.pptx
drsiddhantnagine
 
PPTX
BASICS IN COMPUTER APPLICATIONS - UNIT I
suganthim28
 
PPTX
Five Point Someone – Chetan Bhagat | Book Summary & Analysis by Bhupesh Kushwaha
Bhupesh Kushwaha
 
PPTX
Artificial-Intelligence-in-Drug-Discovery by R D Jawarkar.pptx
Rahul Jawarkar
 
PPTX
CONCEPT OF CHILD CARE. pptx
AneetaSharma15
 
PPTX
Kanban Cards _ Mass Action in Odoo 18.2 - Odoo Slides
Celine George
 
PPTX
How to Manage Leads in Odoo 18 CRM - Odoo Slides
Celine George
 
PDF
Virat Kohli- the Pride of Indian cricket
kushpar147
 
PPTX
How to Track Skills & Contracts Using Odoo 18 Employee
Celine George
 
PPTX
Virus sequence retrieval from NCBI database
yamunaK13
 
DOCX
pgdei-UNIT -V Neurological Disorders & developmental disabilities
JELLA VISHNU DURGA PRASAD
 
PDF
The Minister of Tourism, Culture and Creative Arts, Abla Dzifa Gomashie has e...
nservice241
 
PPTX
CDH. pptx
AneetaSharma15
 
PPTX
CARE OF UNCONSCIOUS PATIENTS .pptx
AneetaSharma15
 
PDF
Review of Related Literature & Studies.pdf
Thelma Villaflores
 
The-Invisible-Living-World-Beyond-Our-Naked-Eye chapter 2.pdf/8th science cur...
Sandeep Swamy
 
Python-Application-in-Drug-Design by R D Jawarkar.pptx
Rahul Jawarkar
 
Measures_of_location_-_Averages_and__percentiles_by_DR SURYA K.pptx
Surya Ganesh
 
A Smarter Way to Think About Choosing a College
Cyndy McDonald
 
SAROCES Action-Plan FOR ARAL PROGRAM IN DEPED
Levenmartlacuna1
 
An introduction to Prepositions for beginners.pptx
drsiddhantnagine
 
BASICS IN COMPUTER APPLICATIONS - UNIT I
suganthim28
 
Five Point Someone – Chetan Bhagat | Book Summary & Analysis by Bhupesh Kushwaha
Bhupesh Kushwaha
 
Artificial-Intelligence-in-Drug-Discovery by R D Jawarkar.pptx
Rahul Jawarkar
 
CONCEPT OF CHILD CARE. pptx
AneetaSharma15
 
Kanban Cards _ Mass Action in Odoo 18.2 - Odoo Slides
Celine George
 
How to Manage Leads in Odoo 18 CRM - Odoo Slides
Celine George
 
Virat Kohli- the Pride of Indian cricket
kushpar147
 
How to Track Skills & Contracts Using Odoo 18 Employee
Celine George
 
Virus sequence retrieval from NCBI database
yamunaK13
 
pgdei-UNIT -V Neurological Disorders & developmental disabilities
JELLA VISHNU DURGA PRASAD
 
The Minister of Tourism, Culture and Creative Arts, Abla Dzifa Gomashie has e...
nservice241
 
CDH. pptx
AneetaSharma15
 
CARE OF UNCONSCIOUS PATIENTS .pptx
AneetaSharma15
 
Review of Related Literature & Studies.pdf
Thelma Villaflores
 

CPU Scheduling Criteria CPU Scheduling Criteria (1).pptx

  • 1. CHAPTER 7 CPU SCHEDULING: BASIC CONCEPTS, SCHEDULING CRITERIA, SCHEDULING ALGORITHMS, ALGORITHM EVALUATION
  • 2. CPU SCHEDULING CRITERIA • Definition: CPU scheduling is a crucial part of operating systems that determines the order and priority of processes to run on a CPU at any given moment. • Purpose: It allows multiple processes to run concurrently on the same processor, optimizing system performance. • Functionality: The CPU scheduler allocates CPU time to processes based on parameters like CPU usage, throughput, turnaround, waiting time, and response time. • Importance: Ensures correct and timely execution of processes, contributing to overall system efficiency. • Algorithms: Different CPU scheduling algorithms exist, each with distinct properties. The choice of algorithm depends on factors such as system requirements and priorities. • Criteria for Comparison: Various criteria, including CPU usage, throughput, turnaround time, waiting time, and response time, are used to compare and evaluate the effectiveness of CPU scheduling algorithms.
  • 3. CPU Scheduling in Operating Systems • Objective: CPU scheduling aims to complete work on time by efficiently utilizing the CPU, allowing one process to use it while others are in standby due to resource unavailability. • Resource Utilization: CPU scheduling ensures optimal use of the CPU by allowing processes to run when others are delayed, such as waiting for I/O resources. • System Improvement: The purpose is to enhance system efficiency, speed, and fairness, ensuring that processes are executed in a timely and equitable manner. • Idle CPU Handling: When the CPU is idle, the operating system's temporary scheduler selects a process from the ready queue, which contains processes prepared for execution. • Launching Processes: The selected process is assigned the CPU for execution, ensuring a continuous flow of tasks and preventing unnecessary CPU downtime. • Temporary Scheduler: The temporary scheduler plays a crucial role in selecting processes for execution, managing the flow of tasks when the CPU becomes available.
  • 4. States of a Process in Operating Systems
  • 5. States of a Process in Operating Systems • New (Create): • Process is about to be created but not yet created. • Program in secondary memory picked up by OS to create the process. • Ready: • Follows the "New" state. • Process is loaded into main memory. • Ready to run and waiting for CPU time. • Maintained in a queue called the ready queue. • Run: • Process chosen from ready queue for execution. • Instructions within the process are executed by a CPU core. • Blocked or Wait: • Occurs when process requests I/O, user input, or access to a critical region. • Process enters a waiting state, not requiring CPU. • Resumes to the ready state once I/O or critical region access is complete.
  • 6. States of a Process in Operating Systems • Terminated or Completed: • Process is killed, and PCB (Process Control Block) is deleted. • Resources allocated to the process are released or deallocated. • Suspend Ready: • Process initially in ready state but swapped out of main memory. • Placed onto external storage by the scheduler. • Transitions back to ready state when brought back to main memory. • Suspend Wait or Suspend Blocked: • Similar to Suspend Ready but involves processes performing I/O operations. • Lack of main memory causes them to move to secondary memory. • Transitions back to Suspend Ready after completing the task. • CPU and I/O Bound Processes: • CPU Bound Process: Intensive in CPU operations. • I/O Bound Process: Intensive in I/O operations.
  • 7. How does a process move between different states in an operating system? A process can move between different states in an operating system based on its execution status and resource availability. • New to Ready: • Process is created and in the new state. • Moves to the ready state when the operating system allocates necessary resources. • Ready to Running: • CPU becomes available. • Operating system selects a process from the ready queue based on scheduling algorithms. • Process moves to the running state for execution. • Running to Blocked: • Process needs to wait for an event (e.g., I/O operation or system call). • Moves to the blocked state until the required event occurs.
  • 8. How does a process move between different states in an operating system? A process can move between different states in an operating system based on its execution status and resource availability. • Running to Ready: • Running process is preempted by the operating system. • Moves to the ready state, often due to a higher-priority process becoming ready. • Blocked to Ready: • Event a blocked process was waiting for occurs. • Process moves to the ready state, ready for execution. • Running to Terminated: • Process completes execution or is terminated by the operating system. • Moves to the terminated state.
  • 9. Type of Scheduler in Operating Systems
  • 10. Types of Schedulers – Short, Middle & Long Term • Long-term Scheduler (Job Scheduler): • Objective: Determines how many processes should stay in the ready state, deciding the degree of multiprogramming. • Frequency: Runs infrequently, as its decisions last for a long time. • Impact: Influences overall system performance by controlling the number of processes in the ready state.
  • 11. Types of Schedulers - Short, Middle & Long Term • Short-term Scheduler (CPU Scheduler): • Objective: Decides which process to execute next and initiates context switching. • Dispatcher: Utilizes a dispatcher (software) to move processes between ready and running states. • Frequency: Runs frequently, managing the immediate execution of processes. • Alias: Also known as the CPU scheduler.
  • 12. Types of Schedulers - Short, Middle & Long Term • Middle-term Scheduler: • Objective: Makes decisions regarding process suspension, especially for swapping between main memory and secondary storage. • Swapping: Involves moving processes to and from main memory to optimize resource usage. • Frequency: Runs when needed, typically to manage the degree of multiprogramming. • Impact: Affects system performance by regulating the presence of processes in main memory.
  • 13. Multiprogramming • Preemption – Process is forcefully removed from CPU. Pre-emotion is also called time sharing or multitasking. • Non-preemption – Processes are not removed until they complete the execution. Once control is given to the CPU for a process execution, till the CPU releases the control by itself, control cannot be taken back forcibly from the CPU.
  • 14. Operation on the Process • 1. Creation: The process will be ready once it has been created, enter the ready queue (main memory), and be prepared for execution. • 2. Planning: The operating system picks one process to begin executing from among the numerous processes that are currently in the ready queue. Scheduling is the process of choosing the next process to run. • 3. Application: The processor begins running the process as soon as it is scheduled to run. During execution, a process may become blocked or wait, at which point the processor switches to executing the other processes. • 4. Killing or Deletion: The OS will terminate the process once its purpose has been fulfilled. The process’s context will be over there.
  • 15. Multiple Choice Questions 1. What is the purpose of the Long-term Scheduler in an operating system? • A) Decides process execution order • B) Manages context switching • C) Determines degree of multiprogramming • D) Handles I/O operations 2. Which scheduler runs infrequently and influences the overall system performance? • A) Short-term Scheduler • B) Long-term Scheduler • C) Medium-term Scheduler • D) CPU Scheduler
  • 16. Multiple Choice Questions 3. What does the Short-term Scheduler (CPU Scheduler) primarily decide? • A) Degree of multiprogramming • B) Process suspension • C) Process execution order • D) Swapping decisions 4. What is the primary function of the Medium-term Scheduler? • A) Determines degree of multiprogramming • B) Manages context switching • C) Makes decisions about process suspension and swapping • D) Allocates CPU time
  • 17. Multiple Choice Questions 5. When does a process move from the Ready to Running state in the context of scheduling? • A) When it completes execution • B) When the CPU becomes available • C) When it needs to wait for an event • D) When a higher-priority process becomes ready 6. What is the primary purpose of context switching in an operating system? • A) Allocating CPU time to processes • B) Saving and restoring the CPU state for process switching • C) Making decisions about process suspension • D) Determining the degree of multiprogramming
  • 18. Multiple Choice Questions 7. In which state does a process wait for an event, such as I/O operation or user input? • A) Ready • B) Blocked or Wait • C) Running • D) Terminated 8. When does a process move from the Running to the Ready state? • A) When it completes execution • B) When it needs to wait for an event • C) When preempted by the operating system • D) When the CPU becomes available
  • 19. Multiple Choice Questions 9. What is the role of the dispatcher in the context of scheduling? • A) Determines degree of multiprogramming • B) Manages context switching • C) Allocates CPU time to processes • D) Makes decisions about process suspension 10. What does the term "CPU Bound Process" refer to? • A) Intensive in I/O operations • B) Intensive in CPU operations • C) Ready for execution • D) Completed its execution