Chapter 1: Introduction CSS503 Systems Programming

Slides:



Advertisements
Similar presentations
Processes and Threads Chapter 3 and 4 Operating Systems: Internals and Design Principles, 6/E William Stallings Patricia Roy Manatee Community College,
Advertisements

Principles of I/O Hardware I/O Devices Block devices, Character devices, Others Speed Device Controllers Separation of electronic from mechanical components.
Interactive lesson about operating system
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.
Lecture Objectives: 1)Explain the limitations of flash memory. 2)Define wear leveling. 3)Define the term IO Transaction 4)Define the terms synchronous.
CMPT 300: Operating Systems I Dr. Mohamed Hefeeda
CMPT 300: Final Review Chapters 8 – Memory Management: Ch. 8, 9 Address spaces Logical (virtual): generated by the CPU Physical: seen by the memory.
Figure 2.8 Compiler phases Compiling. Figure 2.9 Object module Linking.
1 School of Computing Science Simon Fraser University CMPT 300: Operating Systems I Dr. Mohamed Hefeeda.
Introduction to Kernel
CMPT 300: Final Review Chapters 8 – Memory Management: Ch. 8, 9 Address spaces Logical (virtual): generated by the CPU Physical: seen by the memory.
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 Device Management The von Neumann Architecture System Architecture Device Management Polling Interrupts DMA operating systems.
1.1 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts School of Computing Science Simon Fraser University CMPT 300: Operating Systems I Instructor:
Chapter 1: IntroductionDhamdhere: Operating Systems— A Concept-Based Approach Slide No: 1 Copyright ©2005 Overview of Operating Systems Chapters 1 and.
Chapter 2: Computer-System Structures
What do operating systems do? manage processes manage memory and computer resources provide security features execute user programs make solving user.
Chapter 2 The OS, the Computer, and User Programs Copyright © 2008.
I/O Tanenbaum, ch. 5 p. 329 – 427 Silberschatz, ch. 13 p
Chapter 3 Operating Systems Introduction to CS 1 st Semester, 2015 Sanghyun Park.
OPERATING SYSTEM OVERVIEW. Contents Basic hardware elements.
Chapter 1. Introduction What is an Operating System? Mainframe Systems
Contact Information Office: 225 Neville Hall Office Hours: Monday and Wednesday 12:00-1:00 and by appointment.
Recall: Three I/O Methods Synchronous: Wait for I/O operation to complete. Asynchronous: Post I/O request and switch to other work. DMA (Direct Memory.
Operating Systems and Networks AE4B33OSS Introduction.
Chapter 1: Introduction. 1.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 1: Introduction What Operating Systems Do Computer-System.
Chapter 4 Memory Management Virtual Memory.
We will focus on operating system concepts What does it do? How is it implemented? Apply to Windows, Linux, Unix, Solaris, Mac OS X. Will discuss differences.
Silberschatz, Galvin and Gagne  2002 Modified for CSCI 399, Royden, Operating System Concepts Operating Systems Lecture 4 Computer Systems Review.
1 Lecture 1: Computer System Structures We go over the aspects of computer architecture relevant to OS design  overview  input and output (I/O) organization.
Review of Computer System Organization. Computer Startup For a computer to start running when it is first powered up, it needs to execute an initial program.
Operating Systems: Summary INF1060: Introduction to Operating Systems and Data Communication.
CSCI/CMPE 4334 Operating Systems Review: Exam 1 1.
Introduction to Operating Systems Concepts
Introduction to Kernel
Chapter 2: Computer-System Structures(Hardware)
Applied Operating System Concepts
Chapter 2: Computer-System Structures
Processes and threads.
Chapter 1: Introduction
Operating Systems CMPSC 473
CS 6560: Operating Systems Design
Chapter 1: Introduction
Computer Architecture
Chapter 1: Introduction
Chapter 1: Introduction
OS Virtualization.
Structure of Processes
Chapter 1: Intro (excerpt)
CPSC 457 Operating Systems
What is an Operating System?
Module 2: Computer-System Structures
Mid Term review CSC345.
Chapter 8: Memory management
Outline Module 1 and 2 dealt with processes, scheduling and synchronization Next two modules will deal with memory and storage Processes require data to.
Today’s agenda Hardware architecture and runtime system
Lecture Topics: 11/1 General Operating System Concepts Processes
Computer Organization
Process Control B.Ramamurthy 2/22/2019 B.Ramamurthy.
Module 2: Computer-System Structures
CS149D Elements of Computer Science
Unix Process Control B.Ramamurthy 4/11/2019 B.Ramamurthy.
CS 143A Principles of Operating Systems
Process Description and Control in Unix
Process Description and Control in Unix
Chapter 2: Computer-System Structures
Chapter 2: Computer-System Structures
Module 2: Computer-System Structures
Contact Information Office: 225 Neville Hall Office Hours: Monday and Wednesday 12:00-1:00 and by appointment. Phone:
Module 2: Computer-System Structures
Presentation transcript:

Chapter 1: Introduction CSS503 Systems Programming Prof. Munehiro Fukuda Computing & Software Systems University of Washington Bothell CSS503 Chapter 1: Introduction

Defining Operating Systems Goals Execute user programs and make solving user problems easier Making the computer system convenient to use Using computer hardware in an efficient manner Definitions Resource allocator – manages and allocates resources Control program – controls the execution of user programs and operations of I/O devices Kernel – the one program running at all times (all else being application programs) CSS503 Chapter 1: Introduction

Computer System Components CSS503 Chapter 1: Introduction

Operating-System Operations Protection Distinguishing user and kernel I/O Management Asynchronous I/Os Process Management Launching, synchronizing, and terminating programs Memory Management Giving each task a independent logical address space Storage Management Giving logical views of disk spaces, (i.e. directories and files) CSS503 Chapter 1: Introduction

Chapter 1: Introduction Dual-Mode Operation User Mode: Non-privileged operations only Kernel Mode: All operations (including I/O instructions) Transition User to Kernel: Interrupts, system calls, and traps Kernel to User: A special instr. such as IRET CSS503 Chapter 1: Introduction

Chapter 1: Introduction I/O Management requesting process waiting device driver Interrupt handler Hardware data transfer user kernel time Faster CPU/Memory versus Slower I/Os Synchronous I/O or CPU I/O CPU takes care of All I/O operations. Polling wastes CPU time. CSS503 Chapter 1: Introduction

I/O Management (Cont’d) a requesting process replaced with another one device driver Interrupt handler Hardware data transfer user kernel time interrupts DMA Device interrupts and DMA Asynchronous I/O DMA takes care of I/O data transfers. Devices interrupt CPU when they are ready. CSS503 Chapter 1: Introduction

Chapter 1: Introduction Process Management Process Control Block and Logical Address A program in execution Process needs: CPU, memory, Files, I/Os etc. OS must supports: Creation: loading it in memory Synchronization/communication: having a process wait for another. Termination: clean it up from memory Process ID Text (Code + Global Data) UID GID EUID EGID Directory Entry TTY Heap Signal Dispatch Table Memory Map stdin priority 1 stdout Intr. mask 2 stderr registers 3 Stack CPU Status File Descriptors trek.txt CSS503 Chapter 1: Introduction

Chapter 1: Introduction Memory Management Process A’s Logical Address Physical Address Space Providing each process with a logical address space Mapping logical address to physical address (paging and segmentation) Facilitating virtual memory using disk Text Heap Process B’s Logical Address Text Heap Process C Text Stack Heap Stack Virtual Memory in Disk Stack CSS503 Chapter 1: Introduction

Chapter 1: Introduction Storage Management Process 1 1 2 3 stdin stdout stderr Disk partitioning Allowing multiple file systems File and directory management Logical to physical mapping File operations open, read, write, seek, close Boot sector, partition table Superblock 1 File descriptors File table entry inode Linux Process 2 1 2 3 stdin stdout stderr Superblock 2 File descriptors NTFS CSS503 Chapter 1: Introduction

Chapter 1: Introduction Memory Hierarchy Important Rules on Storage Operations Inclusion property Memory coherence Level Size Speed (ns) Managed by Registers 1KB 0.25 ~ 0.5 Compiler Cache 16MB 0.5 ~ 25 Hardware Main memory 16GB 80 ~ 250 OS Hard disks Several TB 5000 CPU Core 1 Core 2 Reg Reg L1 L1 L2 Cache Main Memory Hard disks Hard disks Hard disks CSS503 Chapter 1: Introduction

Chapter 1: Introduction Discussion Solve Text Exercises: 1.6 (Privileged Instructions) 1.8 (CPU Mode) 1.20 (DMA) 1.22 (Cache Memory) CSS503 Chapter 1: Introduction