Download presentation
Presentation is loading. Please wait.
Published byDerrick Simmons Modified over 9 years ago
1
Copyright ©: Nahrstedt, Angrave, Abdelzaher1 Operating System Overview Tarek Abdelzaher Lawrence Angrave Vikram Adve
2
Copyright ©: Nahrstedt, Angrave, Abdelzaher 2 Today’s Objectives By the end of the hour you should be able to: Explain the main purpose of operating systems and describe milestones of OS evolution Explain fundamental machine concepts such as: Instruction processing, Memory hierarchy, Interrupts, and I/O Explain fundamental OS concepts such as: System calls, processes, synchronization, Files Explain the POSIX standard (UNIX specification)
3
Copyright ©: Nahrstedt, Angrave, Abdelzaher 3 Today’s Applications BrowserSecond Life Yahoo Chat Client Pop Mail Application Software HardwareNetwork
4
Copyright ©: Nahrstedt, Angrave, Abdelzaher 4 Application Requirements BrowserSecond Life Yahoo Chat Client Pop Mail Application Software HardwareNetwork Read/write Display Print Store Send/receive
5
Copyright ©: Nahrstedt, Angrave, Abdelzaher 5 BrowserSecond Life Yahoo Chat Client Pop Mail Application Software HardwareNetwork Read/write Display Print Store Read/write Display Print Store Send/receive Application Requirements
6
Copyright ©: Nahrstedt, Angrave, Abdelzaher 6 BrowserSecond Life Yahoo Chat Client Pop Mail Application Software HardwareNetwork Read/write Display Print Store Read/write Display Print Store Send/receive Read/write Display Print Store Send/receive Application Requirements
7
Copyright ©: Nahrstedt, Angrave, Abdelzaher 7 BrowserSecond Life Yahoo Chat Client Pop Mail Application Software HardwareNetwork Read/write Display Print Store Read/write Display Print Store Send/receive Read/write Display Print Store Send/receive Display Store Print Read/write Application Requirements
8
Copyright ©: Nahrstedt, Angrave, Abdelzaher 8 Delegate Common Functions? BrowserSecond Life Yahoo Chat Client Pop Mail Application Software HardwareNetwork Read/write Display Print Store Read/write Display Print Store Send/receive Read/write Display Print Store Send/receive Display Store Print Read/write
9
Copyright ©: Nahrstedt, Angrave, Abdelzaher 9 Delegate Common Functions to an Operating System Web ServerSecond Life Yahoo Chat Pop Mail Application Software Operating System NetworkHardware Read/Write Standard Output Device Control File System Communication
10
Copyright ©: Nahrstedt, Angrave, Abdelzaher 10 OS Exports a Virtual Machine Interface Web ServerSecond Life Yahoo Chat Pop Mail Application Software Operating System NetworkHardware Read/Write Standard Output Device Control File System Communication Standard Operating System Interface (Virtual Machine)
11
Copyright ©: Nahrstedt, Angrave, Abdelzaher 11 Increase Portability = Minimize Machine-Specific Code Web ServerSecond Life Yahoo Chat Pop Mail Application Software Network Hardware Machine specific part Read/Write Standard Output Device Control File System Communication Operating System (machine independent part) Standard Operating System Interface (Virtual Machine)
12
Copyright ©: Nahrstedt, Angrave, Abdelzaher 12 Web ServerSecond Life Yahoo Chat Pop Mail Application Software Network Hardware Machine specific part Read/Write Standard Output Device Control File System Communication Operating System (machine independent part) Standard Operating System Interface (Virtual Machine) Portable Increase Portability = Minimize Machine-Specific Code
13
Copyright ©: Nahrstedt, Angrave, Abdelzaher 13 Web ServerSecond Life Yahoo Chat Pop Mail Application Software Read/Write Standard Output Device Control File System Communication Operating System (machine independent part) Standard Operating System Interface (Virtual Machine) Portable OS Runs on Multiple Platforms while Presenting same Interface
14
Copyright ©: Nahrstedt, Angrave, Abdelzaher 14 Web ServerSecond Life Yahoo Chat Pop Mail Application Software Network Hardware Machine specific part Read/Write Standard Output Device Control File System Communication Operating System (machine independent part) Standard Operating System Interface (Virtual Machine) Portable OS Runs on Multiple Platforms while Presenting same Interface
15
Copyright ©: Nahrstedt, Angrave, Abdelzaher 15 POSIX – The UNIX Interface Standard Web ServerSecond Life Yahoo Chat Pop Mail Application Software Network Hardware Machine specific part Read/Write Standard Output Device Control File System Communication Operating System (machine independent part) The POSIX Standard Specifies UNIX Interface Portable
16
Copyright ©: Nahrstedt, Angrave, Abdelzaher 16 A peek into Unix Application Portable OS Layer Libraries Machine-dependent layer User space/level Kernel space/level User/kernel modes are supported by hardware Some systems do not have clear user-kernel boundary
17
Copyright ©: Nahrstedt, Angrave, Abdelzaher 17 Unix: Application Application (E.g., emacs) Portable OS Layer Libraries Machine-dependent layer Written by programmer Compiled by programmer Uses function calls
18
Copyright ©: Nahrstedt, Angrave, Abdelzaher 18 Unix: Libraries Application Portable OS Layer Libraries (e.g., stdio.h) Machine-dependent layer Provided pre-compiled Defined in headers Input to linker (compiler) Invoked like functions May be “resolved” when program is loaded
19
Copyright ©: Nahrstedt, Angrave, Abdelzaher 19 Typical Unix OS Structure Application Portable OS Layer Libraries Machine-dependent layer system calls (read, open..) All “high-level” code
20
Copyright ©: Nahrstedt, Angrave, Abdelzaher 20 Typical Unix OS Structure Application Portable OS Layer Libraries Machine-dependent layer Bootstrap System initialization Interrupt and exception I/O device driver Memory management Kernel/user mode switching Processor management
21
Copyright ©: Nahrstedt, Angrave, Abdelzaher 21 Summary: What is an Operating System? It is an extended machine Hides the messy details which must be performed Presents user with a virtual machine, easier to use It is a resource manager Each program gets time with the resource Each program gets space on the resource
22
Copyright ©: Nahrstedt, Angrave, Abdelzaher 22 History of Operating Systems Early systems bring cards to 1401 read cards to tape put tape on 7094 which does computing put tape on 1401 which prints output Batch Multiprogramming Time sharing Personal
23
Copyright ©: Nahrstedt, Angrave, Abdelzaher 23 History of Operating Systems Structure of a typical job – 2 nd generation
24
Copyright ©: Nahrstedt, Angrave, Abdelzaher 24 History of Operating Systems Multiprogramming/timesharing system – three jobs in memory – 3 rd generation
25
Copyright ©: Nahrstedt, Angrave, Abdelzaher 25 History of Operating Systems Multiprogramming/timesharing system – three jobs in memory – 3 rd generation Memory Management Process Management
26
Copyright ©: Nahrstedt, Angrave, Abdelzaher 26 History of Computer Generations First generation 1945 – 1955 vacuum tubes, plug boards Second generation 1955 - 1965 transistors, batch systems Third generation 1965 – 1980 ICs and multiprogramming Fourth generation 1980 – present personal computers
27
Copyright ©: Nahrstedt, Angrave, Abdelzaher 27 Computer Hardware Review Components of a simple personal computer Bus
28
Copyright ©: Nahrstedt, Angrave, Abdelzaher 28 Large Pentium system
29
Copyright ©: Nahrstedt, Angrave, Abdelzaher 29 Computer Hardware Review Components of a simple personal computer Bus CPU
30
Copyright ©: Nahrstedt, Angrave, Abdelzaher 30 CPU Fetch instruction from code memory Fetch operands from data memory Perform operation (and store result) Go to next instruction
31
Copyright ©: Nahrstedt, Angrave, Abdelzaher 31 CPU Registers Fetch instruction from code memory Fetch operands from data memory Perform operation (and store result) Go to next instruction Note: CPU must maintain certain state Current instructions to fetch (program counter) Location of code memory segment Location of data memory segment
32
Copyright ©: Nahrstedt, Angrave, Abdelzaher 32 CPU Register Examples Hold instruction operands Point to start of Code segment Data segment Stack segment Point to current position of Instruction pointer Stack pointer
33
Copyright ©: Nahrstedt, Angrave, Abdelzaher 33 CPU Register Examples Hold instruction operands Point to start of Code segment Data segment Stack segment Point to current position of Instruction pointer Stack pointer Why stack?
34
Copyright ©: Nahrstedt, Angrave, Abdelzaher 34 Code Layout for Process Processes have three segments: text, data, stack
35
Copyright ©: Nahrstedt, Angrave, Abdelzaher 35 Code Layout for Process Processes have three segments: text, data, stack Where is this stored?
36
Copyright ©: Nahrstedt, Angrave, Abdelzaher 36 Memory Hierarchy Typical memory hierarchy – numbers shown are rough approximations
37
Copyright ©: Nahrstedt, Angrave, Abdelzaher 37 Computer Hardware Review Components of a simple personal computer Bus CPU
38
Copyright ©: Nahrstedt, Angrave, Abdelzaher 38 Computer Hardware Review Components of a simple personal computer Bus CPUMemory
39
Copyright ©: Nahrstedt, Angrave, Abdelzaher 39 Computer Hardware Review Components of a simple personal computer Bus CPUMemory I/O Devices
40
Copyright ©: Nahrstedt, Angrave, Abdelzaher 40 I/O Interrupt Mechanism (a) a) Steps in starting an I/O device and getting interrupt b) How the CPU is interrupted (b)
41
Copyright ©: Nahrstedt, Angrave, Abdelzaher 41 Computer Hardware Review Example I/O Device: Disk Structure of a disk drive
42
Copyright ©: Nahrstedt, Angrave, Abdelzaher 42 Operating System Review: Processes A process tree A created two child processes, B and C B created three child processes, D, E, and F
43
Copyright ©: Nahrstedt, Angrave, Abdelzaher 43 Context Switching How would you switch CPU execution from one process to another?
44
Copyright ©: Nahrstedt, Angrave, Abdelzaher 44 Semaphores Control access to resources
45
Copyright ©: Nahrstedt, Angrave, Abdelzaher 45 Shared Resources, Conflicts, and Deadlocks (a) A potential deadlock. (b) an actual deadlock.
46
Copyright ©: Nahrstedt, Angrave, Abdelzaher 46 Inter-process Communication Two processes connected by a pipe
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.