11/29/2005Comp 120 Fall 20051 29 November 4 to go! Questions? Interrupts and I/O devices.

Slides:



Advertisements
Similar presentations
Cristian Hill. 6.1 Mocking Mr. Rohol is fun Introduction The CPU performs most of the calculations on the PC The CPU is a single chip on the motherboard.
Advertisements

Computer-System Structures Er.Harsimran Singh
COMP375 Computer Architecture and Organization Senior Review.
CSE431 Chapter 6A.1Irwin, PSU, 2008 Chapter 6A: Disk Systems Mary Jane Irwin ( ) [Adapted from Computer Organization.
Section 6.2. Record data by magnetizing the binary code on the surface of a disk. Data area is reusable Allows for both sequential and direct access file.
CPE 442 io.1 Introduction To Computer Architecture CpE 442 I/O Systems.
CSCE 212 Chapter 8 Storage, Networks, and Other Peripherals Instructor: Jason D. Bakos.
04/18/2007CSCI 315 Operating Systems Design1 Mass Storage Structure Notice: The slides for this lecture have been largely based on those accompanying the.
OS2-1 Chapter 2 Computer System Structures. OS2-2 Outlines Computer System Operation I/O Structure Storage Structure Storage Hierarchy Hardware Protection.
11/18/2004Comp 120 Fall November 3 classes to go No class on Tuesday 23 November Last 2 classes will be survey and exam review Interconnect and.
L21 – OS and IO 1 Comp 411– Spring /24/08 Operating System The OS is JUST A PROGRAM but it runs in SUPERVISOR state access to PHYSICAL addresses.
11/17/2005Comp 120 Fall O Fortuna O Fortune, just as the moon you vary your state always increasing or decreasing; the detestable life now difficult.
1 CS222: Principles of Database Management Fall 2010 Professor Chen Li Department of Computer Science University of California, Irvine Notes 01.
1/21/2010CSCI 315 Operating Systems Design1 Computer System Structures Notice: The slides for this lecture have been largely based on those accompanying.
I/0 devices.
04/19/2004CSCI 315 Operating Systems Design1 Mass Storage Structure Notice: The slides for this lecture have been largely based on those accompanying the.
Chapter 2: Computer-System Structures
Secondary Storage Management Hank Levy. 8/7/20152 Secondary Storage • Secondary Storage is usually: –anything outside of “primary memory” –storage that.
Introduction to Database Systems 1 The Storage Hierarchy and Magnetic Disks Storage Technology: Topic 1.
General System Architecture and I/O.  I/O devices and the CPU can execute concurrently.  Each device controller is in charge of a particular device.
Device Management. So far… We have covered CPU and memory management Computing is not interesting without I/Os Device management: the OS component that.
Lecture on Electronic Memories. What Is Electronic Memory? Electronic device that stores digital information Types –Volatile v. non-volatile –Static v.
Storage & Peripherals Disks, Networks, and Other Devices.
Disk Access. DISK STRUCTURE Sector: Smallest unit of data transfer from/to disk; 512B 2/4/8 adjacent sectors transferred together: Blocks Read/write heads.
 Design model for a computer  Named after John von Neuman  Instructions that tell the computer what to do are stored in memory  Stored program Memory.
Chapter 111 Chapter 11: Hardware (Slides by Hector Garcia-Molina,
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 2: Computer-System Structures Computer System Operation I/O Structure Storage.
Chapter 2: Computer-System Structures
Thanks to Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 2 Computer-System Structures n Computer System Operation n I/O Structure.
2: Computer-System Structures
I/O Example: Disk Drives To access data: — seek: position head over the proper track (8 to 20 ms. avg.) — rotational latency: wait for desired sector (.5.
1 Chapter 2: Computer-System Structures  Computer System Operation  I/O Structure  Storage Structure  Storage Hierarchy  Hardware Protection  General.
Chapter 2: Computer-System Structures Computer System Operation I/O Structure Storage Structure Storage Hierarchy Hardware Protection Network Structure.
External Storage Primary Storage : Main Memory (RAM). Secondary Storage: Peripheral Devices –Disk Drives –Tape Drives Secondary storage is CHEAP. Secondary.
2.1 Operating System Concepts Chapter 2: Computer-System Structures Computer System Operation Storage Structure Storage Hierarchy Hardware Protection General.
© 2005 Pearson Addison-Wesley. All rights reserved Figure 2.1 This chapter focuses on key hardware layer components.
Auxiliary Memory Magnetic Disk:
Csci 136 Computer Architecture II – IO and Storage Systems Xiuzhen Cheng
Adapted from Computer Organization and Design, Patterson & Hennessy ECE232: Hardware Organization and Design Part 17: Input/Output Chapter 6
CS 101 – Sept. 28 Main vs. secondary memory Examples of secondary storage –Disk (direct access) Various types Disk geometry –Flash memory (random access)
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.
L20 – OS and IO 1 Comp 411– Fall /09/09 Operating System The OS is JUST A PROGRAM but it runs in SUPERVISOR state access to PHYSICAL addresses access.
IT3002 Computer Architecture
Processor Memory Processor-memory bus I/O Device Bus Adapter I/O Device I/O Device Bus Adapter I/O Device I/O Device Expansion bus I/O Bus.
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 2: Computer-System Structures Computer System Operation I/O Structure Storage.
1 Lecture 23: Storage Systems Topics: disk access, bus design, evaluation metrics, RAID (Sections )
Disk Average Seek Time. Multi-platter Disk platter Disk read/write arm read/write head.
Overview of microcomputer structure and operation
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.
10/15: Lecture Topics Input/Output –Types of I/O Devices –How devices communicate with the rest of the system communicating with the processor communicating.
1 Components of the Virtual Memory System  Arrows indicate what happens on a lw virtual address data physical address TLB page table memory cache disk.
Chapter 2: Computer-System Structures(Hardware)
Chapter 2: Computer-System Structures
Sarah Diesburg Operating Systems CS 3430
Chapter 2: Computer-System Structures
Computer Science 210 Computer Organization
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 2: Computer-System Structures Computer System Operation I/O Structure Storage.
Computer Architecture
Operating System The OS is JUST A PROGRAM
Operating System The OS is JUST A PROGRAM
Computer-System Architecture
Module 2: Computer-System Structures
Difference between Human and Computer
Module 2: Computer-System Structures
Chapter 2: Computer-System Structures
Chapter 2: Computer-System Structures
Module 2: Computer-System Structures
Module 2: Computer-System Structures
Interrupts and Exception Handling
Andy Wang Operating Systems COP 4610 / CGS 5765
Presentation transcript:

11/29/2005Comp 120 Fall November 4 to go! Questions? Interrupts and I/O devices

11/29/2005Comp 120 Fall Interrupts How does the CPU manage SLOW I/O devices? 1.Programmed I/O 2.Interrupt Driven I/O

11/29/2005Comp 120 Fall Polling Advantages Simple No surprises Processor in full control Disadvantages Polling can waste lots of time

11/29/2005Comp 120 Fall Interrupt Driven I/O Advantage CPU only bothered when actually needed Disadvantage Can occur at surprising or inconvenient times Have to save and restore state

11/29/2005Comp 120 Fall MIPS Exceptions Reset Hardware Errors (Check, Bus Error, Cache Error) External Interrupt (6 inputs) Address Error Reserved Instruction TLB Miss System Call Breakpoint Trap Integer Overflow Floating Point Error Timer And a few more

11/29/2005Comp 120 Fall Exception Processing 1.EPC gets address of faulty instruction or of next instruction depending on type of exception 2.Switch to kernel mode 3.Jump to a new location based on type of exception PC  FFFF FFFF BFC for Reset PC  FFFF FFFF BFC for Hardware error PC  FFFF FFFF BFC for external interrupts PC  FFFF FFFF BFC for … 4.Save registers 5.Examine the “cause” register to find out why you came here 6.Branch to code to do the right thing

11/29/2005Comp 120 Fall Magnetic Disk Long term, nonvolatile storage Large, inexpensive, and slow Rotating platter(s) coated with magnetic material Use a movable read/write head to access When magnetized region zips past coils in head, a tiny signal is produced Force current through coils to generate magnetic field to magnetize tiny regions on the disk Use feedback to keep the head in the right place

11/29/2005Comp 120 Fall Outside

11/29/2005Comp 120 Fall Inside

11/29/2005Comp 120 Fall Platters and Heads

11/29/2005Comp 120 Fall Magnetic Disk Organization Cylinder: All tracks under head with arm in a fixed position Read/Write time has 3 components Seek time to move the arm Rotational latency: wait for the desired sector to come by Transfer time: transfer bits

11/29/2005Comp 120 Fall Typical Disk Times Average Seek: 8ms to 12ms –Sum of all possible seek / number of possible seeks –Locality reduces this to maybe only 25% of average number Rotational Latency: –At 5400 RPM  11 ms –At 7200 RPM  8 ms –At RPM  6ms Transfer time depends on: –Transfer size (typical 512 bytes) –Rotation speed –Recording density –Diameter –Typical values: 10 to 40MBytes per second

11/29/2005Comp 120 Fall CD

11/29/2005Comp 120 Fall CRT Display

11/29/2005Comp 120 Fall LCD

11/29/2005Comp 120 Fall Graphics Cards

11/29/2005Comp 120 Fall Polygons to Surfaces Numerical coordinates specify vertex positions in 3D Matrix multiply transforms 3D coordinates to eye coordinates Divide projects 3D to 2D in perspective Pixel processors fill polygons with appropriate colors based on lighting model

11/29/2005Comp 120 Fall Anti-aliasing

11/29/2005Comp 120 Fall Sound Sound is variations in air pressure A microphone converts these into an analog electrical signal An analog-to-digital converter samples this at frequent intervals The resulting numbers are stored in a file (.wav) On playback a digital-to-analog converter changes these numbers into an analog electrical signal And the moving cone of a speaker converts this into varying air pressure

11/29/2005Comp 120 Fall MP3? The sequence of numbers representing typical sounds is VERY redundant –The next value is closely related to the previous –Values aren’t random cause we don’t like noise Extract this redundancy to get compression Lossy compression: Throw less important info away cause listener won’t notice

11/29/2005Comp 120 Fall Cultural Highlight Check out these Christmas lights!

11/29/2005Comp 120 Fall Classes to go 3