Operating Systems CMPSC 473

Slides:



Advertisements
Similar presentations
Processes Management.
Advertisements

More on Processes Chapter 3. Process image _the physical representation of a process in the OS _an address space consisting of code, data and stack segments.
Architectural Support for OS March 29, 2000 Instructor: Gary Kimura Slides courtesy of Hank Levy.
Figure 2.8 Compiler phases Compiling. Figure 2.9 Object module Linking.
U NIVERSITY OF M ASSACHUSETTS, A MHERST Department of Computer Science Emery Berger University of Massachusetts, Amherst Operating Systems CMPSCI 377 Lecture.
OS Fall ’ 02 Introduction Operating Systems Fall 2002.
Architectural Support for Operating Systems. Announcements Most office hours are finalized Assignments up every Wednesday, due next week CS 415 section.
1/27/2010CSCI 315 Operating Systems Design1 Processes Notice: The slides for this lecture have been largely based on those accompanying an earlier version.
OS Spring’03 Introduction Operating Systems Spring 2003.
Advanced OS Chapter 3p2 Sections 3.4 / 3.5. Interrupts These enable software to respond to signals from hardware. The set of instructions to be executed.
1 Last Class: Introduction Operating system = interface between user & architecture Importance of OS OS history: Change is only constant User-level Applications.
1 Process Description and Control Chapter 3 = Why process? = What is a process? = How to represent processes? = How to control processes?
Threads CS 416: Operating Systems Design, Spring 2001 Department of Computer Science Rutgers University
OS Spring’04 Introduction Operating Systems Spring 2004.
1 OS & Computer Architecture Modern OS Functionality (brief review) Architecture Basics Hardware Support for OS Features.
CSE 451: Operating Systems Autumn 2013 Module 6 Review of Processes, Kernel Threads, User-Level Threads Ed Lazowska 570 Allen.
Operating Systems CSE 411 CPU Management Sept Lecture 11 Instructor: Bhuvan Urgaonkar.
CSC 501 Lecture 2: Processes. Process Process is a running program a program in execution an “instantiation” of a program Program is a bunch of instructions.
Operating Systems ECE344 Ashvin Goel ECE University of Toronto OS-Related Hardware.
Computer Architecture and Operating Systems CS 3230: Operating System Section Lecture OS-1 Process Concepts Department of Computer Science and Software.
Lecture 3 Process Concepts. What is a Process? A process is the dynamic execution context of an executing program. Several processes may run concurrently,
Hardware process When the computer is powered up, it begins to execute fetch-execute cycle for the program that is stored in memory at the boot strap entry.
Process by Dr. Amin Danial Asham. References Operating System Concepts ABRAHAM SILBERSCHATZ, PETER BAER GALVIN, and GREG GAGNE.
Operating Systems CSE 411 Introduction and Overview Sept Lecture 2 Instructor: Bhuvan Urgaonkar.
1 CSE451 Architectural Supports for Operating Systems Autumn 2002 Gary Kimura Lecture #2 October 2, 2002.
1 Computer Systems II Introduction to Processes. 2 First Two Major Computer System Evolution Steps Led to the idea of multiprogramming (multiple concurrent.
Operating Systems CMPSC 473 Processes (3) September Lecture 9 Instructor: Bhuvan Urgaonkar.
Process Description and Control Chapter 3. Source Modified slides from Missouri U. of Science and Tech.
Hardware process When the computer is powered up, it begins to execute fetch-execute cycle for the program that is stored in memory at the boot strap entry.
Chapter 2 Process Management. 2 Objectives After finish this chapter, you will understand: the concept of a process. the process life cycle. process states.
Operating Systems CMPSC 473 Introduction and Overview August 24, Lecture 1 Instructor: Bhuvan Urgaonkar.
Operating Systems CMPSC 473 Processes (5) September Lecture 11 Instructor: Bhuvan Urgaonkar.
Interrupts and Exception Handling. Execution We are quite aware of the Fetch, Execute process of the control unit of the CPU –Fetch and instruction as.
CSCI/CMPE 4334 Operating Systems Review: Exam 1 1.
Scheduler activations Landon Cox March 23, What is a process? Informal A program in execution Running code + things it can read/write Process ≠
Introduction to Operating Systems Concepts
Introduction to Operating Systems
Processes and threads.
Process concept.
Process Management Process Concept Why only the global variables?
CS 6560: Operating Systems Design
Lecture Topics: 11/1 Processes Process Management
Chapter 3 – Process Concepts
Process Management Presented By Aditya Gupta Assistant Professor
Overview of today’s lecture
Intro to Processes CSSE 332 Operating Systems
Computer System Overview
Processor Fundamentals
CSE 451: Operating Systems Spring 2012 Module 6 Review of Processes, Kernel Threads, User-Level Threads Ed Lazowska 570 Allen.
Process & its States Lecture 5.
Lecture Topics: 11/1 General Operating System Concepts Processes
Process Description and Control
Architectural Support for OS
Process Description and Control
Processes and Process Management
CSE 451: Operating Systems Autumn 2003 Lecture 2 Architectural Support for Operating Systems Hank Levy 596 Allen Center 1.
Process Description and Control
Process Description and Control
CSE 451: Operating Systems Autumn 2001 Lecture 2 Architectural Support for Operating Systems Brian Bershad 310 Sieg Hall 1.
Process Description and Control
Computer System Overview
CSE 451: Operating Systems Winter 2007 Module 2 Architectural Support for Operating Systems Brian Bershad 562 Allen Center 1.
Operating Systems: A Modern Perspective, Chapter 6
CSE 451: Operating Systems Winter 2003 Lecture 2 Architectural Support for Operating Systems Hank Levy 412 Sieg Hall 1.
Chapter 2 Processes and Threads 2.1 Processes 2.2 Threads
Architectural Support for OS
Process Description and Control
CSE 153 Design of Operating Systems Winter 2019
Chapter 3: Processes Process Concept Process Scheduling
Chapter 13: I/O Systems “The two main jobs of a computer are I/O and [CPU] processing. In many cases, the main job is I/O, and the [CPU] processing is.
Presentation transcript:

Operating Systems CMPSC 473 Processes August 26, 2010 - Lecture 2 Instructor: Bhuvan Urgaonkar

Last class Definition of an operating system Software that virtualizes physical resources for applications CPU, memory, IO devices virtualized to process, virtual memory, and files OS requires a variety of support from hardware For protecting processes from each other and to control their resource usage -> User/Kernel Modes

Announcements A brief tutorial on using gdb in the next class Slides up on Angel

Services & Hardware Support Protection: Kernel/User mode, Protected Instructions, Base & Limit Registers Scheduling: Timer Interrupts: Interrupt Vectors System Calls: Trap Instructions Efficient I/O: Interrupts, Memory-mapping Synchronization: Atomic Instructions Virtual Memory: Translation Lookaside Buffer (TLB)

Interrupts Polling = “are we there yet?” “no!” (repeat…) Inefficient use of resources Annoys the CPU Interrupt = silence, then: “we’re there” I/O device has own processor When finished, device sends interrupt on bus CPU “handles” interrupt

CPU Interrupt Handling Handling interrupts: relatively expensive CPU must: Save hardware state Registers, program counter (Often) disable interrupts (why?) Invoke via in-memory interrupt vector (like trap vector, soon) Enable interrupts Restore hardware state Continue execution of interrupted process

Traps Special conditions detected by architecture E.g.: page fault, write to read-only page, overflow, system call On detecting trap, hardware must: Save process state (PC, stack, etc.) Transfer control to trap handler (in OS) CPU indexes trap vector by trap number Jumps to address Restore process state and resume

Timer OS needs timers for Interrupt vector for timer Time of day CPU scheduling Interrupt vector for timer

Processes

Process: Definition For us: Instance of a program in execution For OS: The collection of data structures that fully describes how far the execution of the program has progressed From kernel’s point of view, an entity to which system resources (CPU time, memory, …) are allocated

Overview of Process-related Topics How a process is born Parent/child relationship fork, clone, … How it leads its life Loaded: Later in the course Executed CPU scheduling Where a process “lives”: Address space OS maintains some info. for each process: PCB Process = Address Space + PCB How processes request services from the OS System calls How processes communicate A variant of processes: threads How processes die

Process Address Space Text section Stack Data Heap Temporary data Function params, return addresses, local variables Data Global variables Heap Used for dynamically allocating memory

Process Life-cycle New: Being created Running: Instructions are being executed Only one process can be in this state at any given time per-CPU Waiting: Waiting for some event to occur (e.g., I/O completion or reception of a signal) Ready: Waiting to be assigned the CPU Terminated: Finished execution