COMPUTER SYSTEMS ARCHITECTURE A NETWORKING APPROACH CHAPTER 12 INTRODUCTION THE MEMORY HIERARCHY CS 147 Nathaniel Gilbert 1.

Slides:



Advertisements
Similar presentations
C SINGH, JUNE 7-8, 2010IWW 2010, ISATANBUL, TURKEY Advanced Computers Architecture, UNIT 2 Advanced Computers Architecture UNIT 2 CACHE MEOMORY Lecture7.
Advertisements

MEMORY popo.
1 Lecture 13: Cache and Virtual Memroy Review Cache optimization approaches, cache miss classification, Adapted from UCB CS252 S01.
M. Mateen Yaqoob The University of Lahore Spring 2014.
Chapter 12 Memory Organization
Cache Memory Locality of reference: It is observed that when a program refers to memory, the access to memory for data as well as code are confined to.
CMPE 421 Parallel Computer Architecture MEMORY SYSTEM.
What is memory? Memory is used to store information within a computer, either programs or data. Programs and data cannot be used directly from a disk or.
1 Lecture 20 – Caching and Virtual Memory  2004 Morgan Kaufmann Publishers Lecture 20 Caches and Virtual Memory.
S.1 Review: The Memory Hierarchy Increasing distance from the processor in access time L1$ L2$ Main Memory Secondary Memory Processor (Relative) size of.
1 Chapter Seven Large and Fast: Exploiting Memory Hierarchy.
Overview: Memory Memory Organization: General Issues (Hardware) –Objectives in Memory Design –Memory Types –Memory Hierarchies Memory Management (Software.
IT Systems Memory EN230-1 Justin Champion C208 –
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.
Data Storage Technology
1 CSE SUNY New Paltz Chapter Seven Exploiting Memory Hierarchy.
Systems I Locality and Caching
C.S. Choy95 COMPUTER ORGANIZATION Logic Design Skill to design digital components JAVA Language Skill to program a computer Computer Organization Skill.
Memory Hierarchy.
Random access memory.
THE MEMORY SYSTEM & INTERCONNECTION STRUCTURE OBJECTIVES Define Memory hierarchy and its characteristics Define various types of memories Define the.
Lecture 19 Today’s topics Types of memory Memory hierarchy.
CS 352 : Computer Organization and Design University of Wisconsin-Eau Claire Dan Ernst Memory Systems How to make the most out of cheap storage.
CS 312 Computer Architecture Memory Basics Department of Computer Science Southern Illinois University Edwardsville Summer, 2015 Dr. Hiroshi Fujinoki
+ CS 325: CS Hardware and Software Organization and Architecture Memory Organization.
1 Virtual Memory Main memory can act as a cache for the secondary storage (disk) Advantages: –illusion of having more physical memory –program relocation.
Introduction to Computer Systems Topics: Theme Five great realities of computer systems (continued) “The class that bytes”
MEMORY ORGANIZATION - Memory hierarchy - Main memory - Auxiliary memory - Cache memory.
Introduction to Virtual Memory and Memory Management
CPS3340 COMPUTER ARCHITECTURE Fall Semester, /3/2013 Lecture 9: Memory Unit Instructor: Ashraf Yaseen DEPARTMENT OF MATH & COMPUTER SCIENCE CENTRAL.
Introduction: Memory Management 2 Ideally programmers want memory that is large fast non volatile Memory hierarchy small amount of fast, expensive memory.
Lecture#15. Cache Function The data that is stored within a cache might be values that have been computed earlier or duplicates of original values that.
Multilevel Caches Microprocessors are getting faster and including a small high speed cache on the same chip.
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.
Semiconductor Memory Types
A memory is just like a human brain. It is used to store data and instructions. Computer memory is the storage space in computer where data is to be processed.
1  1998 Morgan Kaufmann Publishers Chapter Seven.
Jeffrey Ellak CS 147. Topics What is memory hierarchy? What are the different types of memory? What is in charge of accessing memory?
What is it and why do we need it? Chris Ward CS147 10/16/2008.
1 Chapter Seven. 2 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.
Chapter 11 System Performance Enhancement. Basic Operation of a Computer l Program is loaded into memory l Instruction is fetched from memory l Operands.
CS 1410 Intro to Computer Tecnology Computer Hardware1.
Types of RAM (Random Access Memory) Information Technology.
Memory Management memory hierarchy programs exhibit locality of reference - non-uniform reference patterns temporal locality - a program that references.
Cache Advanced Higher.
William Stallings Computer Organization and Architecture 7th Edition
Memory COMPUTER ARCHITECTURE
Yu-Lun Kuo Computer Sciences and Information Engineering
Types of RAM (Random Access Memory)
The Goal: illusion of large, fast, cheap memory
Ramya Kandasamy CS 147 Section 3
Cache Memory Presentation I
CS-301 Introduction to Computing Lecture 17
William Stallings Computer Organization and Architecture 7th Edition
Basic Computer Organization
CS 286: Memory Paging and Virtual Memory
Unit 2 Computer Systems HND in Computing and Systems Development
William Stallings Computer Organization and Architecture 8th Edition
William Stallings Computer Organization and Architecture 8th Edition
Memory Basics Chapter 8.
Memory Organization.
Memory Operation and Performance
MICROPROCESSOR MEMORY ORGANIZATION
Memory Basics Chapter 7.
William Stallings Computer Organization and Architecture 8th Edition
Fundamentals of Computing: Computer Architecture
Cache Memory and Performance
Presentation transcript:

COMPUTER SYSTEMS ARCHITECTURE A NETWORKING APPROACH CHAPTER 12 INTRODUCTION THE MEMORY HIERARCHY CS 147 Nathaniel Gilbert 1

Levels of Performance – You Get What You Pay For Recall:  Dynamic Random Access Memory (DRAM)  Capacitors to store state (0 or 1)  Periodically refreshed  Relatively cheap  Static Random Access Memory (SRAM)  Transistors to store state  Doesn’t need to be refreshed, faster, and uses less power than DRAM  More expensive than DRAM 2

Levels of Performance cont. Currently, one Pound is about 2 US Dollars. R = removable media 3

Levels of Performance cont. Storage Hierarchy – fastest CPU registers at top, slowest tape drives at bottom Pre-fetching – Data transferred between layers is usually bigger than requested. This is to anticipate using the extra blocks of data. 4

Localization of Access – exploiting repetition  Computers tend to access the same locality of memory.  This is partly due to the programmer organizing data in clusters along with the compiler attempting to organize code efficiently.  This localization can be exploited in memory hierarchy. 5

Localization of Access cont.  Exploiting localization of memory access  Keep related data in smaller groups (try not to store all input and output to a single array when reading from/writing to disk)  Only the portion of data the CPU is using should be loaded into faster memory. 6

Localization of Access cont. The following code was used by the author to demonstrate cache action (exploiting localization of memory access) 7

Localization of Access cont.  On a sun workstation (200 MHz CPU, 256 Mbyte main memory, 256 kbyte cache, 4 Gbyte local hard drive), the output was: (Time is system clock ticks) 8

Localization of Access cont.  The reason for the doubling of time is the movement of data up and down the data hierarchy.  The array is sent to higher memory in blocks because the 256 kbytes of cache memory cannot hold the whole object. 9

Instruction and Data Caches – Matching Memory to CPU Speed  A 2 GHz Pentium CPU accesses program memory an average off 0.5 ns just for fetching instructions  DDO DRAM responds within 10 ns. If the CPU only used DRAM, it would result in 20x loss in speed  This is where using SRAM (cache) comes into play  Downfall of cache: Misses (if the desired code is not in the memory segment) may take longer because the memory has to be reloaded Negative cache – (depending on architecture) where negative results (failures) are stored 10

Instruction and Data Caches cont.  Cache is built from SRAM chips, and ideally are made to match the system clock speed of a CPU  The Cache Controller Unit (CCU) and cache memory, are inserted between the CPU and the main memory.  Level 1 and Level 2 cache are different by placement.  Level 1 is on the CPU chip.  Level 2 was generally located off the CPU chip and was slowed down by the system bus. Intel successfully integrated a 128 kbyte L2 cache memory onto the CPU and continues to offer integrated chips. 11

Instruction and Data Caches cont.  Generic System Architecture  Level 1 is the microprocessor with three forms of cache: D-cache – (Data) Fast buffer containing application data I-cache – (Instruction) Speed up executable instruction TLB – (Translation Lookaside Buffer) Stores a map of translated virtual page addresses  Level 2 is Unified cache  Memory – DRAM  CPU and Register file reside in Level 1 Register file – Small amount of memory closest to CPU where data is manipulated 12

Thank You 13