Lecture 11: Caches (Basics) - University of Cretehy425/2013f/lectures/Lec11_caches_basics.pdf ·...
-
Upload
nguyenhanh -
Category
Documents
-
view
215 -
download
0
Transcript of Lecture 11: Caches (Basics) - University of Cretehy425/2013f/lectures/Lec11_caches_basics.pdf ·...
Lecture 11: Caches (Basics)
Iakovos Mavroidis
Computer Science Department
University of Crete
Who Cares about Memory Hierarchy?
Latency lags bandwidth
Memory abstraction in architecture
Levels of Memory Hierarchy
Definition of Cache
Memory Hierarchy: Apple iMac G5 (2005)
iMac’s PowerPC 970 (G5): All caches on-chip
Locality
Memory Hierarchy: Terminology
Cache Hit
Cache Miss
Cache Measures
An example
4 Questions for Memory Hierarchy
Q1: Where to Place Blocks?
Simplest Cache: Direct Mapped
1 KB Direct Mapped Cache, 32B blocks
Direct Mapped Cache
Two-way Set Associative Cache
Two-way Set Associative Cache
Cache Mapping Example
Q2: How is a block found in the cache
Q3: Which block is replace on a miss
Q4: What happens on a write?
Write Buffers for Write-Through Caches
Another Write Buffer Optimization
Average Memory Access Time (AMAT)
Example
Example
Example
Example
Overlapping memory latency in OOO processors