Workshop Week 12 PDF
Workshop Week 12 PDF
Workshop Week 12 PDF
Problem # 1
A computer system uses 16-bit memory addresses. It has a 2K-byte cache organized in a
direct-mapped manner with 64 bytes per cache block. Assume that the size of each memory
word is 1 byte.
(a) Calculate the number of bits in each of the Tag, Block, and Word fields of the
memory address.
(b) When a program is executed, the processor reads data sequentially from the
following word addresses:
All the above addresses are shown in decimal values. Assume that the cache is initially empty.
For each of the above addresses, indicate whether the cache access will result in a hit or a
miss. In case of a miss, indicate if it is a compulsory, capacity or conflict miss.
Problem # 2
Repeat Problem # 1, if the cache is organized as a 2-way set-associative cache that uses the
LRU replacement algorithm.