Similar questions 4 more →
Cache Memory


Answer & solution
Official answer: A
Step through it (9 steps)
There are 256×1024/32=8192 cache lines and hence 8192 tag-directory entries. The preceding calculation gives a 16-bit address tag. Each entry additionally has the explicitly specified 2 valid bits, 1 modified bit and 1 replacement bit, for 16+2+1+1=20 bits. The directory is 8192×20=163, 840 bits=160 Kibits, option A (printed as Kbits). Count entries per cache line, not per set; the problem explicitly assigns the replacement bit per entry.
Check: Four ways do not mean only one tag per set: each way stores a distinct block and needs its own tag and metadata. Equivalently, 2048 sets×4 entries/set×20 bits/entry=163840 bits, confirming the per-line calculation.