Skip to content
Official PYQ · 2014

GATE CS 2014 Set 2 Q44 — Memory Hierarchy: Cache, Main Memory and Secondary Storage

Explain with AI

If the associativity of a processor cache is doubled while keeping the capacity and block size unchanged, which one of the following is guaranteed to be NOT affected?

Choose one option
View worked solution

Answer: D

Let us analyze how changing the cache associativity affects each parameter. Let:

  • CC = Cache capacity
  • BB = Block size
  • PP = Associativity (number of blocks per set)

The number of sets in the cache is given by:

S=CB×PS = \frac{C}{B \times P}

When the associativity PP is doubled (P′=2PP' = 2P) while keeping capacity CC and block size BB constant:

  1. Number of sets (SS): It is halved (S′=S/2S' = S/2). Therefore, the number of set index bits decreases by 11 (since log⁡2(S′)=log⁡2(S)−1\log_2(S') = \log_2(S) - 1). This directly changes the width of the set index decoder (Option B is affected).
  2. Tag bits: Since the set index bits decrease by 11 and the block offset bits remain unchanged, the number of tag bits must increase by 11 to maintain the same physical address width. This changes the width of the tag comparator (Option A is affected).
  3. Way selection multiplexer: The multiplexer must select 11 out of PP ways. Since associativity PP is doubled, the size of this multiplexer increases from PP-to-11 to 2P2P-to-11 (Option C is affected).
  4. Processor to main memory data bus: The width of this bus depends on the system architecture and the block size transferred between the cache and main memory. It is entirely independent of the internal cache associativity (Option D is NOT affected).

Free practice · Your answers on this page are not saved.

Published
Report a correction
Keep exploringMore Memory Hierarchy: Cache, Main Memory and Secondary Storage questions