Chapter 1 Introduction n Why study Operating Systems

  • Slides: 19
Download presentation
Chapter 1: Introduction n Why study Operating Systems? 知之者不如好之者,好之者不如乐之者

Chapter 1: Introduction n Why study Operating Systems? 知之者不如好之者,好之者不如乐之者

What is an Operating System? n “Like a government!” between a user of a

What is an Operating System? n “Like a government!” between a user of a computer and the computer hardware n Operating system goals: l Execute user programs and make solving user problems easier. l Make the computer system convenient to use n Use the computer hardware in an efficient manner

Increasing Software Complexity From MIT’s 6. 033 course

Increasing Software Complexity From MIT’s 6. 033 course

Functionality comes with great complexity! Pentium IV Chipset Proc Caches Busses Memory adapters Controllers

Functionality comes with great complexity! Pentium IV Chipset Proc Caches Busses Memory adapters Controllers I/O Devices: Disks Displays Keyboards Networks

Sample of Computer Architecture Topics Input/Output and Storage Disks, WORM, Tape VLSI Coherence, Bandwidth,

Sample of Computer Architecture Topics Input/Output and Storage Disks, WORM, Tape VLSI Coherence, Bandwidth, Latency L 2 Cache L 1 Cache Instruction Set Architecture Network Communication Addressing, Protection, Exception Handling Pipelining, Hazard Resolution, Superscalar, Reordering, Prediction, Speculation, Vector, Dynamic Compilation Pipelining and Instruction Level Parallelism Other Processors Emerging Technologies Interleaving Bus protocols DRAM Memory Hierarchy RAID

What if we didn’t have an Operating System? n 人 操作 l 用户独占全机 l

What if we didn’t have an Operating System? n 人 操作 l 用户独占全机 l CPU等待人 操作 n 脱机输入/输出

What if only one application? MS-DOS

What if only one application? MS-DOS

More complex OS: Multiple Apps n Multi-programming (多道程序) n Problem: Run multiple applications in

More complex OS: Multiple Apps n Multi-programming (多道程序) n Problem: Run multiple applications in such a way that they are protected from one another n Goal: l Keep User Programs from Crashing OS l Keep User Programs from Crashing each other l [Keep Parts of OS from crashing other parts? ] n (Some of the required) Mechanisms: l Address Translation l Dual Mode Operation n Simple Policy: l Programs are not allowed to read/write memory of other Programs or of Operating System

Time-Sharing Systems–Interactive Computing n The CPU is multiplexed among several jobs that are kept

Time-Sharing Systems–Interactive Computing n The CPU is multiplexed among several jobs that are kept in memory and on disk (the CPU is allocated to a job only if the job is in memory) n A job swapped in and out of memory to the disk n On-line communication between the user and the system is provided l When the operating system finishes the execution of one command, it seeks the next “control statement” from the user’s keyboard l 多路性 l 独立性 l 及时性 l 交互性

Real-Time Systems n Often used as a control device in a dedicated application such

Real-Time Systems n Often used as a control device in a dedicated application such as controlling scientific experiments, medical imaging systems, industrial control systems, and some display systems n Well-defined fixed-time constraints n Real-Time systems may be either hard or soft real-time n 实时控制 n 实时信息处理 n 可靠性

Real-Time Systems (Cont. ) n Hard real-time: l Secondary storage limited or absent, data

Real-Time Systems (Cont. ) n Hard real-time: l Secondary storage limited or absent, data stored in short term memory, or read-only memory (ROM) l Conflicts with time-sharing systems, not supported by general-purpose operating systems n Soft real-time l Limited utility in industrial control of robotics l Integrate-able with time-share systems l Useful in applications (multimedia, virtual reality) requiring tight response times

Handheld Systems n Personal Digital Assistants (PDAs) n Cellular telephones n Issues: l Limited

Handheld Systems n Personal Digital Assistants (PDAs) n Cellular telephones n Issues: l Limited memory l Slow processors l Small display screens

Migration of Operating-System Concepts and Features

Migration of Operating-System Concepts and Features

OS Characteristics n 并发(Concurrence) n 共享(Sharing)� n 虚拟(Virtual) n 异步(Asynchronism)

OS Characteristics n 并发(Concurrence) n 共享(Sharing)� n 虚拟(Virtual) n 异步(Asynchronism)

Why Study Operating Systems? n Learn how to build complex systems: l How can

Why Study Operating Systems? n Learn how to build complex systems: l How can you manage complexity for future projects? n Engineering issues: l Why is the web so slow sometimes? Can you fix it? l What features should be in the next mars Rover? l How do large distributed systems work? (Kazaa, etc)

Why Study Operating Systems? n Buying and using a personal computer: l Why different

Why Study Operating Systems? n Buying and using a personal computer: l Why different PCs with same CPU behave differently l How to choose a processor (Opteron, Itanium, Celeron, Pentium, Hexium)? [ Ok, made last one up ] l Should you get Windows XP, 2000, Linux, Mac OS …? l Why does Microsoft have such a bad name? n Business issues: l Should your division buy thin-clients vs PC? n Security, viruses, and worms l What exposure do you have to worry about?