GATE Computer ScienceVery hardGATE CS (PYQ pattern)

A 4-way set-associative cache of 64 KB uses 32-byte blocks and 32-bit physical addresses. Each block has one valid bit and one dirty bit in addition to its tag (ignore replacement bits). The total tag-store size is:

  1. A. 40960 bits
  2. B. 38912 bits
  3. C. 36864 bits
  4. D. 45056 bits

Correct answer: A. 40960 bits

Blocks = 64 KB/32 B = 2048 and sets = 2048/4 = 512, so offset = 5 bits, index = 9 bits and tag = 32 − 14 = 18 bits. Each block needs 18 + 2 = 20 bits, giving 2048 × 20 = 40960 bits; leaving out the dirty bit gives 38912.

More Computer Organization and Architecture questions

Exams that ask this topic