Architecture Background

Slides:



Advertisements
Similar presentations
Computer System Organization Computer-system operation – One or more CPUs, device controllers connect through common bus providing access to shared memory.
Advertisements

Chapter 6 Computer Architecture
CMPE 421 Parallel Computer Architecture MEMORY SYSTEM.
Chapter 5 Computing Components. The (META) BIG IDEA Cool, idea but maybe too big DATA – Must be stored somewhere in a storage device PROCESSING – Data.
1 Lecture 2: Review of Computer Organization Operating System Spring 2007.
Computer System Overview
1 Computer System Overview OS-1 Course AA
Memory Organization.
Computer System Overview
University College Cork IRELAND Hardware Concepts An understanding of computer hardware is a vital prerequisite for the study of operating systems.
Operating Systems Béat Hirsbrunner Main Reference: William Stallings, Operating Systems: Internals and Design Principles, 6 th Edition, Prentice Hall 2009.
Computer System Overview Chapter 1. Basic computer structure CPU Memory memory bus I/O bus diskNet interface.
1 SRAM: –value is stored on a pair of inverting gates –very fast but takes up more space than DRAM (4 to 6 transistors) DRAM: –value is stored as a charge.
1 Computer System Overview Chapter 1 Review of basic hardware concepts.
© Janice Regan, CMPT 300, May CMPT 300 Introduction to Operating Systems Operating Systems Overview: Using Hardware.
Chapter 1 Computer System Overview Patricia Roy Manatee Community College, Venice, FL ©2008, Prentice Hall Operating Systems: Internals and Design Principles,
Computer Systems Overview. Page 2 W. Stallings: Operating Systems: Internals and Design, ©2001 Operating System Exploits the hardware resources of one.
1 Computer System Overview Chapter 1. 2 n An Operating System makes the computing power available to users by controlling the hardware n Let us review.
CS 1308 Computer Literacy and the Internet Computer Systems Organization.
Operating Systems and Networks AE4B33OSS Introduction.
Ihr Logo Operating Systems Internals & Design Principles Fifth Edition William Stallings Chapter 1 Computer System Overview.
Introduction to Computer Architecture. What is binary? We use the decimal (base 10) number system Binary is the base 2 number system Ten different numbers.
Computer Architecture And Organization UNIT-II Structured Organization.
Interrupts, Buses Chapter 6.2.5, Introduction to Interrupts Interrupts are a mechanism by which other modules (e.g. I/O) may interrupt normal.
CPU How It Works. 2 Generic Block Diagram CPU MemoryInputOutput Address Bus Data Bus.
Fall 2000M.B. Ibáñez Lecture 17 Paging Hardware Support.
2 nd Year - 1 st Semester Asst. Lect. Mohammed Salim Computer Architecture I 1.
Introduction to Computer Architecture. What is binary? We use the decimal (base 10) number system Binary is the base 2 number system Ten different numbers.
Computer Architecture Lecture 2 System Buses. Program Concept Hardwired systems are inflexible General purpose hardware can do different tasks, given.
© 2004, D. J. Foreman 1 Computer Organization. © 2004, D. J. Foreman 2 Basic Architecture Review  Von Neumann ■ Distinct single-ALU & single-Control.
CSCI-365 Computer Organization Lecture Note: Some slides and/or pictures in the following are adapted from: Computer Organization and Design, Patterson.
CS 1308 Computer Literacy and the Internet. Objectives In this chapter, you will learn about:  The components of a computer system  Putting all the.
Introduction: Memory Management 2 Ideally programmers want memory that is large fast non volatile Memory hierarchy small amount of fast, expensive memory.
1 Copyright © 2010, Elsevier Inc. All rights Reserved Chapter 2 Parallel Hardware and Parallel Software An Introduction to Parallel Programming Peter Pacheco.
Lecture 1: Review of Computer Organization
1 Chapter Seven CACHE MEMORY AND VIRTUAL MEMORY. 2 SRAM: –value is stored on a pair of inverting gates –very fast but takes up more space than DRAM (4.
Assoc. Prof. Dr. Ahmet Turan ÖZCERİT.  What Operating Systems Do  Computer-System Organization  Computer-System Architecture  Operating-System Structure.
1 Computer Architecture. 2 Basic Elements Processor Main Memory –volatile –referred to as real memory or primary memory I/O modules –secondary memory.
Chapter 11 System Performance Enhancement. Basic Operation of a Computer l Program is loaded into memory l Instruction is fetched from memory l Operands.
Computer Systems Overview. Lecture 1/Page 2AE4B33OSS W. Stallings: Operating Systems: Internals and Design, ©2001 Operating System Exploits the hardware.
1 Computer System Overview Chapter 1. 2 Operating System Exploits the hardware resources of one or more processors Provides a set of services to system.
CS161 – Design and Architecture of Computer
GCSE OCR Computing A451 The CPU Computing hardware 1.
Chapter 1 Computer System Overview
Cache Memory.
Chapter 8: Main Memory.
CS161 – Design and Architecture of Computer
Memory and cache CPU Memory I/O.
CS352H: Computer Systems Architecture
Introduction to Computer Architecture
Assembly Language for Intel-Based Computers, 5th Edition
Computer System Overview
Chapter 3 Top Level View of Computer Function and Interconnection
Teaching Computing to GCSE
Memory and cache CPU Memory I/O.
ECEG-3202 Computer Architecture and Organization
Introduction to Computer Architecture
Chapter 6 Memory System Design
Chapter 5: Computer Systems Organization
Morgan Kaufmann Publishers Memory Hierarchy: Virtual Memory
Computer Organization
Chapter 1 Computer System Overview
Cache Memory and Performance
Chapter01 Computer System Overview
Presentation transcript:

Architecture Background Von Neumann architecture - cpu = ALU + control unit - memory - devices Above connected with buses ALU – carry out instruction, may have more than one execution unit Program counter – memory address of next instruction to fetch..

Hardware instructions Program counter – memory address of next instruction to fetch.. i = i + 1; One high-level-language instruction can be many assembly instructions. (Load, Add, Store) What about programs running in parallel?

More executing code Memory - programs (code and data) must be in memory to run and use --> process Start Fetch Execute Halt Fetch and Execute cycles

Interrupts Interrupts - A mechanism where modules may interrupt the normal processing of the processor. Used to improve processor efficiency. (I/O is slow, so overlap I/O with cpu operations) How do interrupts affect the Fetch and Execute cycles picture?

Interrupt cycle Add in an interrupt cycle. If there is a pending interrupt, processor suspends execution of running program and executes interrupt handler If interrupts are disabled Start Fetch Execute Halt Intr enabled Check interrupts

Memory Hierarchy Speed Cost Size Volatile NON-Volatile CPU Registers L1 Cache $ Volatile RAM main memory L2 Cache $ NON-Volatile Speed Cost Size Disks Optical Tapes C.Flash

Memory Load a word from memory to a register Store a register to memory RAM – usually too small – need swap (virtual memory) Use disks for swap space as well as to store programs and data. Unused memory is wasted memory!

Cache Memory Faster, but more expensive than RAM Cache Lines Memory is accessed during fetch-execute cycle If we can cache data in faster cache memory we can achieve better perform. Hits and misses (like hits and outs)

Cache Memory The more hits we have with cache the better the performance. A “hit ratio” is like a batting average. The cache is much smaller than what is being cached. Have multiple levels of cache. Also, we'll consider having data in main memory vs. secondary memory later.

Cache Memory The key to having a good hit ratio is to take advantage of the principle of locality. Memory references tend to cluster while a program is running. (for both data and instructions) In a loop the same instructions are executed many times. When working with data, it may be accessed many times.

Cache Memory Over a short period of time the same memory is accessed many times. --> which is why using cache works Can apply the same principle over many levels of the memory hierarchy. L1 Cache – L2 Cache – RAM – swap KB MB GB GB

Locality Two types of locality Spatial – access to memory locations are clustered. - execute instructions sequentially - access to data locations when processing a table Temporal – access to memory that was recently used. - a loop has instructions repeated

Cache Memory Have H be the “hit ratio”. Let L1 cache access time be 0.1 uS Let L2 cache access time be 1 uS If H is 0.95 then (0.95)(0.1 uS) + (0.05)(0.1 uS + 1uS) = 0.095 + 0.055 = 0.15uS Hits + misses Access time is much closer to L1 access time with the high hit ratio.

More memory issues Virtual address -> physical address mapping done by memory management unit (MMU) Context switch – switching from one program to another - slow (expensive) - copy registers - consider cache lines

Current CPU technology Intel/AMD – x86, x64 Dual core, Quad core multiprocessor Sparc Niagara T1 and T2 - 8 core, 4 and 8 threads per core Power use a big issue now