SlideShare ist ein Scribd-Unternehmen logo
1 von 2
MODULE IN ITE229 - OPERATING SYSTEMS 12
                                Prepared by: For-Ian V. Sandoval



                               LESSON 6
                        PROCESSOR MANAGEMENT


          The heart of managing the processor comes down to two related
issues:

   •      Ensuring that each process and application receives enough of the
          processor's time to function properly
   •      Using as many processor cycles as possible for real work

     The basic unit of software that the operating system deals with in
scheduling the work done by the processor is either a process or a thread,
depending on the operating system.

       It's tempting to think of a process as an application, but that gives
an incomplete picture of how processes relate to the operating system
and hardware. The application you see (word processor, spreadsheet or
game) is, indeed, a process, but that application may cause several other
processes to begin, for tasks like communications with other devices or
other computers. There are also numerous processes that run without
giving you direct evidence that they ever exist. For example, Windows XP
and UNIX can have dozens of background processes running to handle
the network, memory management, disk management, virus checks and
so on.

      A process, then, is software that performs some action and can be
controlled -- by a user, by other applications or by the operating system.

      It is processes, rather than applications, that the operating system
controls and schedules for execution by the CPU. In a single-tasking
system, the schedule is straightforward. The operating system allows the
application to begin running, suspending the execution only long enough
to deal with interrupts and user input.

        Interrupts are special signals sent by hardware or software to the
CPU. It's as if some part of the computer suddenly raised its hand to ask for
the CPU's attention in a lively meeting. Sometimes the operating system
will schedule the priority of processes so that interrupts are masked -- that
is, the operating system will ignore the interrupts from some sources so that
a particular job can be finished as quickly as possible. There are some
interrupts (such as those from error conditions or problems with memory)
MODULE IN ITE229 - OPERATING SYSTEMS 13
                              Prepared by: For-Ian V. Sandoval

that are so important that they can't be ignored. These non-maskable
interrupts (NMIs) must be dealt with immediately, regardless of the other
tasks at hand.

       While interrupts add some complication to the execution of
processes in a single-tasking system, the job of the operating system
becomes much more complicated in a multi-tasking system. Now, the
operating system must arrange the execution of applications so that you
believe that there are several things happening at once. This is
complicated because the CPU can only do one thing at a time. Today's
multi-core processors and multi-processor machines can handle more
work, but each processor core is still capable of managing one task at a
time.

     In order to give the appearance of lots of things happening at the
same time, the operating system has to switch between different
processes thousands of times a second. Here's how it happens:

   •   A process occupies a certain amount of RAM. It also makes use of
       registers, stacks and queues within the CPU and operating-system
       memory space.
   •   When two processes are multi-tasking, the operating system allots a
       certain number of CPU execution cycles to one program.
   •   After that number of cycles, the operating system makes copies of
       all the registers, stacks and queues used by the processes, and
       notes the point at which the process paused in its execution.
   •   It then loads all the registers, stacks and queues used by the second
       process and allows it a certain number of CPU cycles.
   •   When those are complete, it makes copies of all the registers, stacks
       and queues used by the second program, and loads the first
       program

Weitere ähnliche Inhalte

Was ist angesagt?

How Operating System Works
How Operating System WorksHow Operating System Works
How Operating System Works
guevarra_2000
 
Real Time Operating System
Real Time Operating SystemReal Time Operating System
Real Time Operating System
vivek223
 
operating system question bank
operating system question bankoperating system question bank
operating system question bank
rajatdeep kaur
 
Multiprogramming&timesharing
Multiprogramming&timesharingMultiprogramming&timesharing
Multiprogramming&timesharing
Tanuj Tyagi
 
Process management in os
Process management in osProcess management in os
Process management in os
Sumant Diwakar
 
Operating system and its function
Operating system and its functionOperating system and its function
Operating system and its function
Nikhi Jain
 
REAL TIME OPERATING SYSTEM
REAL TIME OPERATING SYSTEMREAL TIME OPERATING SYSTEM
REAL TIME OPERATING SYSTEM
prakrutijsh
 

Was ist angesagt? (20)

RTOS- Real Time Operating Systems
RTOS- Real Time Operating Systems RTOS- Real Time Operating Systems
RTOS- Real Time Operating Systems
 
Class 1: Introduction - What is an Operating System?
Class 1: Introduction - What is an Operating System?Class 1: Introduction - What is an Operating System?
Class 1: Introduction - What is an Operating System?
 
Real time operating systems (rtos) concepts 9
Real time operating systems (rtos) concepts 9Real time operating systems (rtos) concepts 9
Real time operating systems (rtos) concepts 9
 
Real Time Operating System
Real Time Operating SystemReal Time Operating System
Real Time Operating System
 
How Operating System Works
How Operating System WorksHow Operating System Works
How Operating System Works
 
Unit 1 introduction to operating system
Unit 1 introduction to operating systemUnit 1 introduction to operating system
Unit 1 introduction to operating system
 
Types of operating system unit 1 by Ram K Paliwal
Types of operating system  unit 1 by Ram K PaliwalTypes of operating system  unit 1 by Ram K Paliwal
Types of operating system unit 1 by Ram K Paliwal
 
Unit 4 Real Time Operating System
Unit 4 Real Time Operating SystemUnit 4 Real Time Operating System
Unit 4 Real Time Operating System
 
Introduction to Operating System
Introduction to Operating SystemIntroduction to Operating System
Introduction to Operating System
 
REAL TIME OPERATING SYSTEM PART 1
REAL TIME OPERATING SYSTEM PART 1REAL TIME OPERATING SYSTEM PART 1
REAL TIME OPERATING SYSTEM PART 1
 
Introduction to Operating system
Introduction to Operating system Introduction to Operating system
Introduction to Operating system
 
Real Time Operating System
Real Time Operating SystemReal Time Operating System
Real Time Operating System
 
Types Of Operating Systems
Types Of Operating SystemsTypes Of Operating Systems
Types Of Operating Systems
 
Real Time Operating Systems
Real Time Operating SystemsReal Time Operating Systems
Real Time Operating Systems
 
operating system question bank
operating system question bankoperating system question bank
operating system question bank
 
Multiprogramming&timesharing
Multiprogramming&timesharingMultiprogramming&timesharing
Multiprogramming&timesharing
 
Process management in os
Process management in osProcess management in os
Process management in os
 
Operating system and its function
Operating system and its functionOperating system and its function
Operating system and its function
 
REAL TIME OPERATING SYSTEM
REAL TIME OPERATING SYSTEMREAL TIME OPERATING SYSTEM
REAL TIME OPERATING SYSTEM
 
OS
OSOS
OS
 

Andere mochten auch (6)

Management process
Management processManagement process
Management process
 
Operating system - Process and its concepts
Operating system - Process and its conceptsOperating system - Process and its concepts
Operating system - Process and its concepts
 
Process management
Process managementProcess management
Process management
 
Process management in os
Process management in osProcess management in os
Process management in os
 
Operating Systems - Processor Management
Operating Systems - Processor ManagementOperating Systems - Processor Management
Operating Systems - Processor Management
 
Processes of management
Processes of managementProcesses of management
Processes of management
 

Ähnlich wie Lesson 6 Processor Management

Intermediate Operating Systems
Intermediate Operating SystemsIntermediate Operating Systems
Intermediate Operating Systems
John Cutajar
 
Operting system
Operting systemOperting system
Operting system
KAnurag2
 
Operating system 2
Operating system 2Operating system 2
Operating system 2
matsapit
 

Ähnlich wie Lesson 6 Processor Management (20)

3330701_unit-1_operating-system-concepts.pdf
3330701_unit-1_operating-system-concepts.pdf3330701_unit-1_operating-system-concepts.pdf
3330701_unit-1_operating-system-concepts.pdf
 
Intermediate Operating Systems
Intermediate Operating SystemsIntermediate Operating Systems
Intermediate Operating Systems
 
LM1 - Computer System Overview, system calls
LM1 - Computer System Overview, system callsLM1 - Computer System Overview, system calls
LM1 - Computer System Overview, system calls
 
Bedtime Stories on Operating Systems.pdf
Bedtime Stories on Operating Systems.pdfBedtime Stories on Operating Systems.pdf
Bedtime Stories on Operating Systems.pdf
 
Operating system
Operating systemOperating system
Operating system
 
Operating System and related questions
Operating System and related questionsOperating System and related questions
Operating System and related questions
 
Ch1 - OS.pdf
Ch1 - OS.pdfCh1 - OS.pdf
Ch1 - OS.pdf
 
Compyter system softwere
Compyter system softwereCompyter system softwere
Compyter system softwere
 
Os notes 1_5
Os notes 1_5Os notes 1_5
Os notes 1_5
 
Unit 1 q&a
Unit  1 q&aUnit  1 q&a
Unit 1 q&a
 
Unit 1os processes and threads
Unit 1os processes and threadsUnit 1os processes and threads
Unit 1os processes and threads
 
Reformat PPT.pptx
Reformat PPT.pptxReformat PPT.pptx
Reformat PPT.pptx
 
4-Process control block.pptx
4-Process control block.pptx4-Process control block.pptx
4-Process control block.pptx
 
4-Process control block.pptx
4-Process control block.pptx4-Process control block.pptx
4-Process control block.pptx
 
Operting system
Operting systemOperting system
Operting system
 
Introduction to OS 1.ppt
Introduction to OS 1.pptIntroduction to OS 1.ppt
Introduction to OS 1.ppt
 
Advanced computer architecture lesson 1 and 2
Advanced computer architecture lesson 1 and 2Advanced computer architecture lesson 1 and 2
Advanced computer architecture lesson 1 and 2
 
Operating system 2
Operating system 2Operating system 2
Operating system 2
 
OPERATING SYSTEM - SHORT NOTES
OPERATING SYSTEM - SHORT NOTESOPERATING SYSTEM - SHORT NOTES
OPERATING SYSTEM - SHORT NOTES
 
ch1.ppt
ch1.pptch1.ppt
ch1.ppt
 

Mehr von Laguna State Polytechnic University

Mehr von Laguna State Polytechnic University (20)

Number Theory - Lesson 1 - Introduction to Number Theory
Number Theory - Lesson 1 - Introduction to Number TheoryNumber Theory - Lesson 1 - Introduction to Number Theory
Number Theory - Lesson 1 - Introduction to Number Theory
 
Formal Logic - Lesson 8 - Predicates and Quantifiers
Formal Logic - Lesson 8 - Predicates and QuantifiersFormal Logic - Lesson 8 - Predicates and Quantifiers
Formal Logic - Lesson 8 - Predicates and Quantifiers
 
Machine Learning Algorithms (Part 1)
Machine Learning Algorithms (Part 1)Machine Learning Algorithms (Part 1)
Machine Learning Algorithms (Part 1)
 
Artificial Intelligence Algorithms
Artificial Intelligence AlgorithmsArtificial Intelligence Algorithms
Artificial Intelligence Algorithms
 
Formal Logic - Lesson 7 - Rules of Inference
Formal Logic - Lesson 7 - Rules of InferenceFormal Logic - Lesson 7 - Rules of Inference
Formal Logic - Lesson 7 - Rules of Inference
 
Formal Logic - Lesson 6 - Switching Circuits
Formal Logic - Lesson 6 - Switching CircuitsFormal Logic - Lesson 6 - Switching Circuits
Formal Logic - Lesson 6 - Switching Circuits
 
Formal Logic - Lesson 5 - Logical Equivalence
Formal Logic - Lesson 5 - Logical EquivalenceFormal Logic - Lesson 5 - Logical Equivalence
Formal Logic - Lesson 5 - Logical Equivalence
 
Formal Logic - Lesson 4 - Tautology, Contradiction and Contingency
Formal Logic - Lesson 4 - Tautology, Contradiction and ContingencyFormal Logic - Lesson 4 - Tautology, Contradiction and Contingency
Formal Logic - Lesson 4 - Tautology, Contradiction and Contingency
 
Formal Logic - Lesson 3 - Truth Tables
Formal Logic - Lesson 3 - Truth TablesFormal Logic - Lesson 3 - Truth Tables
Formal Logic - Lesson 3 - Truth Tables
 
Formal Logic - Lesson 2 - Logical Connectives
Formal Logic - Lesson 2 - Logical ConnectivesFormal Logic - Lesson 2 - Logical Connectives
Formal Logic - Lesson 2 - Logical Connectives
 
Formal Logic - Lesson 1 - Introduction to Logic
Formal Logic - Lesson 1 - Introduction to LogicFormal Logic - Lesson 1 - Introduction to Logic
Formal Logic - Lesson 1 - Introduction to Logic
 
Ethical Issues and Relevant Laws on Computing
Ethical Issues and Relevant Laws on ComputingEthical Issues and Relevant Laws on Computing
Ethical Issues and Relevant Laws on Computing
 
Number Systems Basic Concepts
Number Systems Basic ConceptsNumber Systems Basic Concepts
Number Systems Basic Concepts
 
Number Systems Basic Concepts
Number Systems Basic ConceptsNumber Systems Basic Concepts
Number Systems Basic Concepts
 
Exploring the Difference Between Information Technology and Information System
Exploring the Difference Between Information Technology and Information SystemExploring the Difference Between Information Technology and Information System
Exploring the Difference Between Information Technology and Information System
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Introduction to Computers
Introduction to ComputersIntroduction to Computers
Introduction to Computers
 
Introduction to Computing Logic Formulation
Introduction to Computing Logic FormulationIntroduction to Computing Logic Formulation
Introduction to Computing Logic Formulation
 
Oasis of Sparkling and Refreshing Truisms
Oasis of Sparkling and Refreshing TruismsOasis of Sparkling and Refreshing Truisms
Oasis of Sparkling and Refreshing Truisms
 
My Teacher Got IT v2.0 - Software Installation Track
My Teacher Got IT v2.0 - Software Installation TrackMy Teacher Got IT v2.0 - Software Installation Track
My Teacher Got IT v2.0 - Software Installation Track
 

Kürzlich hochgeladen

1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
QucHHunhnh
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
heathfieldcps1
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global Impact
PECB
 

Kürzlich hochgeladen (20)

Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptx
 
Python Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxPython Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docx
 
General Principles of Intellectual Property: Concepts of Intellectual Proper...
General Principles of Intellectual Property: Concepts of Intellectual  Proper...General Principles of Intellectual Property: Concepts of Intellectual  Proper...
General Principles of Intellectual Property: Concepts of Intellectual Proper...
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 
Class 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfClass 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdf
 
On National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan FellowsOn National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan Fellows
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
 
Sociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning ExhibitSociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning Exhibit
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot Graph
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and Mode
 
How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17
 
Food Chain and Food Web (Ecosystem) EVS, B. Pharmacy 1st Year, Sem-II
Food Chain and Food Web (Ecosystem) EVS, B. Pharmacy 1st Year, Sem-IIFood Chain and Food Web (Ecosystem) EVS, B. Pharmacy 1st Year, Sem-II
Food Chain and Food Web (Ecosystem) EVS, B. Pharmacy 1st Year, Sem-II
 
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
 
Role Of Transgenic Animal In Target Validation-1.pptx
Role Of Transgenic Animal In Target Validation-1.pptxRole Of Transgenic Animal In Target Validation-1.pptx
Role Of Transgenic Animal In Target Validation-1.pptx
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global Impact
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxBasic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
 

Lesson 6 Processor Management

  • 1. MODULE IN ITE229 - OPERATING SYSTEMS 12 Prepared by: For-Ian V. Sandoval LESSON 6 PROCESSOR MANAGEMENT The heart of managing the processor comes down to two related issues: • Ensuring that each process and application receives enough of the processor's time to function properly • Using as many processor cycles as possible for real work The basic unit of software that the operating system deals with in scheduling the work done by the processor is either a process or a thread, depending on the operating system. It's tempting to think of a process as an application, but that gives an incomplete picture of how processes relate to the operating system and hardware. The application you see (word processor, spreadsheet or game) is, indeed, a process, but that application may cause several other processes to begin, for tasks like communications with other devices or other computers. There are also numerous processes that run without giving you direct evidence that they ever exist. For example, Windows XP and UNIX can have dozens of background processes running to handle the network, memory management, disk management, virus checks and so on. A process, then, is software that performs some action and can be controlled -- by a user, by other applications or by the operating system. It is processes, rather than applications, that the operating system controls and schedules for execution by the CPU. In a single-tasking system, the schedule is straightforward. The operating system allows the application to begin running, suspending the execution only long enough to deal with interrupts and user input. Interrupts are special signals sent by hardware or software to the CPU. It's as if some part of the computer suddenly raised its hand to ask for the CPU's attention in a lively meeting. Sometimes the operating system will schedule the priority of processes so that interrupts are masked -- that is, the operating system will ignore the interrupts from some sources so that a particular job can be finished as quickly as possible. There are some interrupts (such as those from error conditions or problems with memory)
  • 2. MODULE IN ITE229 - OPERATING SYSTEMS 13 Prepared by: For-Ian V. Sandoval that are so important that they can't be ignored. These non-maskable interrupts (NMIs) must be dealt with immediately, regardless of the other tasks at hand. While interrupts add some complication to the execution of processes in a single-tasking system, the job of the operating system becomes much more complicated in a multi-tasking system. Now, the operating system must arrange the execution of applications so that you believe that there are several things happening at once. This is complicated because the CPU can only do one thing at a time. Today's multi-core processors and multi-processor machines can handle more work, but each processor core is still capable of managing one task at a time. In order to give the appearance of lots of things happening at the same time, the operating system has to switch between different processes thousands of times a second. Here's how it happens: • A process occupies a certain amount of RAM. It also makes use of registers, stacks and queues within the CPU and operating-system memory space. • When two processes are multi-tasking, the operating system allots a certain number of CPU execution cycles to one program. • After that number of cycles, the operating system makes copies of all the registers, stacks and queues used by the processes, and notes the point at which the process paused in its execution. • It then loads all the registers, stacks and queues used by the second process and allows it a certain number of CPU cycles. • When those are complete, it makes copies of all the registers, stacks and queues used by the second program, and loads the first program