12/2/091 What is an Operating System Andy Konwinski CS61CL Dec 2, 2009 Lecture 13 UCB CS61CL F09 Lec 13.

Slides:



Advertisements
Similar presentations
CSC 360- Instructor: K. Wu Overview of Operating Systems.
Advertisements

Memory Management Paging &Segmentation CS311, CS350 & CS550.
Operating Systems ECE344 Ding Yuan Final Review Lecture 13: Final Review.
Computer Organization CS224 Fall 2012 Lesson 44. Virtual Memory  Use main memory as a “cache” for secondary (disk) storage l Managed jointly by CPU hardware.
CMPT 300: Operating Systems I Dr. Mohamed Hefeeda
1 Operating Systems and Protection CS Goals of Today’s Lecture How multiple programs can run at once  Processes  Context switching  Process.
Input-output and Communication Prof. Sin-Min Lee Department of Computer Science.
Architectural Support for OS March 29, 2000 Instructor: Gary Kimura Slides courtesy of Hank Levy.
1 School of Computing Science Simon Fraser University CMPT 300: Operating Systems I Dr. Mohamed Hefeeda.
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.
Computer Science 162 Discussion Section Week 2. Agenda Recap “What is an OS?” and Why? Process vs. Thread “THE” System.
OS Spring’03 Introduction Operating Systems Spring 2003.
Computer System Structures memory memory controller disk controller disk controller printer controller printer controller tape-drive controller tape-drive.
1 Last Class: Introduction Operating system = interface between user & architecture Importance of OS OS history: Change is only constant User-level Applications.
1/21/2010CSCI 315 Operating Systems Design1 Computer System Structures Notice: The slides for this lecture have been largely based on those accompanying.
OS Spring’04 Introduction Operating Systems Spring 2004.
1 OS & Computer Architecture Modern OS Functionality (brief review) Architecture Basics Hardware Support for OS Features.
Virtual Machine Monitors CSE451 Andrew Whitaker. Hardware Virtualization Running multiple operating systems on a single physical machine Examples:  VMWare,
I/O Tanenbaum, ch. 5 p. 329 – 427 Silberschatz, ch. 13 p
Basics of Operating Systems March 4, 2001 Adapted from Operating Systems Lecture Notes, Copyright 1997 Martin C. Rinard.
1 CS503: Operating Systems Part 1: OS Interface Dongyan Xu Department of Computer Science Purdue University.
CS 162 Discussion Section Week 1 (9/9 – 9/13) 1. Who am I? Kevin Klues Office Hours:
CS 153 Design of Operating Systems Spring 2015 Final Review.
Chapter 1. Introduction What is an Operating System? Mainframe Systems
Architecture Support for OS CSCI 444/544 Operating Systems Fall 2008.
CSE 451: Operating Systems Section 10 Project 3 wrap-up, final exam review.
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 ECE344 Ashvin Goel ECE University of Toronto OS Design.
Memory Management 3 Tanenbaum Ch. 3 Silberschatz Ch. 8,9.
CS 153 Design of Operating Systems Spring 2015 Lecture 2: Intro and Architectural Support for Operating Systems.
Chapter 2: Computer-System Structures Computer System Operation I/O Structure Storage Structure Storage Hierarchy Hardware Protection Network Structure.
Background: Operating Systems Brad Karp UCL Computer Science CS GZ03 / M th November, 2008.
Operating Systems and Systems Programming CS162 Teaching Staff.
Operating Systems Lecture 1 Jinyang Li. Class goals Understand how an OS works by studying its: –Design principles –Implementation realities Gain some.
Lecture Topics: 10/29 Architectural support for operating systems –timers –kernel mode –system calls –protected instructions.
Operating Systems Security
Operating Systems Engineering Based on MIT (2012, lec3) Recitation 2: OS Organization.
Processes and Virtual Memory
Lecture 26 Virtual Machine Monitors. Virtual Machines Goal: run an guest OS over an host OS Who has done this? Why might it be useful? Examples: Vmware,
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.
CS2100 Computer Organisation Virtual Memory – Own reading only (AY2015/6) Semester 1.
Lecture 5 Rootkits Hoglund/Butler (Chapters 1-3).
Operating Systems CMPSC 473 Introduction and Overview August 24, Lecture 1 Instructor: Bhuvan Urgaonkar.
CS 162 Discussion Section Week 2. Who am I? Prashanth Mohan Office Hours: 11-12pm Tu W at.
Introduction to Operating Systems Concepts
Computer Organization & Design 计算机组成与设计
Virtual Machine Monitors
CS 3214 Computer Systems Lecture 9 Godmar Back.
Introduction to Operating Systems
Operating Systems Lecture 2.
Chapter 2: Computer-System Structures
Memory Management Paging (continued) Segmentation
x86 segmentation, page tables, and interrupts
CS703 - Advanced Operating Systems
Operating Systems and Systems Programming
Introduction to Operating Systems
Memory Management Paging (continued) Segmentation
Computer-System Architecture
Operating Systems Lecture 2.
Architectural Support for OS
CSE 451: Operating Systems Autumn 2003 Lecture 2 Architectural Support for Operating Systems Hank Levy 596 Allen Center 1.
CSE 451: Operating Systems Autumn 2001 Lecture 2 Architectural Support for Operating Systems Brian Bershad 310 Sieg Hall 1.
CSE 451: Operating Systems Autumn Module 24 Virtual Machine Monitors
CSE 451: Operating Systems Winter 2003 Lecture 2 Architectural Support for Operating Systems Hank Levy 412 Sieg Hall 1.
Architectural Support for OS
Chapter 2: Computer-System Structures
Chapter-1 Computer is an advanced electronic device that takes raw data as an input from the user and processes it under the control of a set of instructions.
Chapter 2: Computer-System Structures
Memory Management Paging (continued) Segmentation
Presentation transcript:

12/2/091 What is an Operating System Andy Konwinski CS61CL Dec 2, 2009 Lecture 13 UCB CS61CL F09 Lec 13

Today What is an operating system Dual mode operation: kernel vs. user mode Current trends and issues 12/2/09 UCB CS61CL F09 Lec 13 2

What is an Operating System Resources –Textbooks I like: 12/2/09 UCB CS61CL F09 Lec 13 3

What is an Operating System No single all encompassing definition Used to be an actual person, an “operator” –You were operator for your CAL16 processor General definition: –A layer of software that provides user programs with a simpler, cleaner, model of the computer and handles the messy job of managing the resources. 12/2/09 UCB CS61CL F09 Lec 13 4

What is an Operating System Where the OS fits in 12/2/09 UCB CS61CL F09 Lec 13 5 (modified version of fig 1-1, tanenbaum, pg2) software hardware Operating System Kernel mode User mode Music player reader Web browser

Part 1: Clean abstractions of HW Hardware is messy (e.g. assembly lang., interacting with a device) Application developers want useful high level abstractions 12/2/09 UCB CS61CL F09 Lec 13 6

Example: File System Application level: files Hardware level: controller, blocks Operating system to manage the mapping between files and blocks, also protection. 12/2/09 UCB CS61CL F09 Lec 13 7 MS Word Foo.txt File System Operating System Sector #, disk# Disk controller Disk Cylinder, sector, head Network controller Frames, MAC address NIC

Part 2: Resource manager Multiplex one set of hardware resources between apps/users –CPU/Memory/cache –I/O devices »Communication (network cards, hard drive) »Human I/O (mouse, keyboard, monitor, printer) 12/2/09 UCB CS61CL F09 Lec 13 8 CPU Hard Drive network … Andy: MS Word Andy: Day of Defeat Jamie: WinAmp

Part 2b: fault/performance isolation Resources should be shared fairly Isolation between users (processes) –Fault isolation: when one program crashes, it should not cause others to crash –Performance isolation: e.g. if spotlight runs, my Quicktime movie shouldn’t skip. 12/2/09 UCB CS61CL F09 Lec 13 9

Example: virtual memory Each application sees continuous, nearly infinite, mem. address namespace Hardware provides: finite memory, page table base register, TLB, disk Operating system: orchestrates. –manages page table entries (e.g. updating Valid bit when swapping), flushes the TLB when necessary, pages to disk, etc. 12/2/09 UCB CS61CL F09 Lec 13 10

Administrative Midterm 2 back last week, regrades done This is final class Optional lab on threads Regrade requests for Midterm 2 due by end of day Friday Review lecture next week 12/2/09 UCB CS61CL F09 Lec 13 11

Dual mode operation Hardware knows that an operating system will be used, and that it needs more privileges than application software. Hardware bit for user/kernel mode. Need kernel mode access for: –Accessing kernel data structures, e.g. list open files –Mapping device mem to main mem, e.g. graphics card –Kernel registers, e.g. page table offset –Privileged instructions, e.g. switch to kernel mode 12/2/09 UCB CS61CL F09 Lec 13 12

Switching between User/Kernel mode 12/2/09 UCB CS61CL F09 Lec Application code: OS code: KernelUser Mode bit: Instruction 1 Instruction 2 … Syscall Instruction N … Bootup instructions … Dispatch application … Handle syscall … Finish syscall

Interrupts Hardware interrupts Software-generated interrupts (called Traps) –System calls: user has OS do something on its behalf, trap or syscall instruction. –Exceptions: if privileged instruction called when in user-level, handled similar to a system call 12/2/09 UCB CS61CL F09 Lec 13 14

Trends OS used to handle concurrency for us (time sharing), now applications are making smarter use of concurrency (threading) –ParLab Cloud computing –RAD Lab 12/2/09 UCB CS61CL F09 Lec 13 15

Summary OS multiplexes hardware resources & provides clean abstraction for applications. Dual mode operation, interrupts, exceptions Parallel and cloud computing Take CS162 to pick up where we’re leaving off and actually build an OS (and see more of me)! 12/2/09 UCB CS61CL F09 Lec 13 16