Computer Science 251
Computer Organization and Architecture
Dickinson College
Fall Semester 2005
Grant Braught
Class #20 - Cache Memory
Main Ideas For Today 
- Direct Mapped Cache
- Fully Associative Cache
- Set Associative Cache
- Cache Coherency
- Thrashing
- Cache Replacement Policies
- Cache Coherency
Reading Assignment 
- Null & Lobur, Chapter 6, Section 6.4, 6.6.
Lecture Slides 
- Class #20 - Cache Memory
(Slides are only available for download from on-campus locations)
Web Sites Related to Today's Topic 
- CPU Cache
- A set of pages from the Wikipedia describing cache memory, how it works and how it can be implemented.
- The Fundamentals of Cache
- A page that discusses cache memory, including direct, fully associative and set-associative caches.
- Memory Cache Simulation
- A java applet that animates the operation of cache memory. The animation will work for direct, fully associative and set associative caches.
Homework Assigned Today 
Due Date: 11/21/05
- Null & Lobur, Chapter 6: #2, #4, #6, #9.
NOTE: For #9, assume the cache was initially empty. Thus, you must count the first four misses when computing your hit ratio.
- Answer the following question using the system from problem #2. Where in the cache (which block and byte) would the byte with main memory address
12938410 be located if it were in the cache?
- Write a paragraph discussing the relative potential for thrashing to occur in the three cache mapping schemes that we have discussed (Direct, Fully Associative, Set Associative).
Project Assigned Today 