170 likes | 289 Views
COMPSCI 210 Semester 1 - 2014. Tutorial 11 Cache. Exercise 11.1 Solution. A direct mapped cache with 16 cache lines. Each line has 4 words, and each word is one byte. The address bus is 16 bits. (a) How many bits are needed for representing the offset within a cache line (answer: 2)
E N D
COMPSCI 210Semester 1 - 2014 Tutorial 11 Cache
Exercise 11.1 Solution • A direct mapped cache with 16 cache lines. Each line has 4 words, and each word is one byte. The address bus is 16 bits. • (a) How many bits are needed for representing the offset within a cache line (answer: 2) • (b) How many bits are needed for the index field (answer 4) • (c) How many bits are there in the tag field (answer 10) • (d) How much data can be held in the cache (answer 64 bytes) • (e) Figure out whether each of the following read accesses is a hit or a miss