An 8-way set associative cache of size 64 KB (1 KB = 1024 bytes) is used in a system with 32-bit address. The address is sub-divided into TAG, INDEX, and BLOCK OFFSET. The number of bits in the TAG is ______.
For a $K$-way set-associative cache, the cache is divided into sets, and an address splits as: tag | set index | block offset.
Number of sets $=\dfrac{\text{cache size}}{K\times\text{block size}}$. The set index and the block offset together address one set's worth of data: $$\text{index bits}+\text{offset bits}=\log_2\frac{\text{cache size}}{K}=\log_2\frac{64\text{ KB}}8=\log_2 2^{13}=13.$$ (This does not depend on the block size.)
Tag bits $=32-13=\mathbf{19}$.
More Memory Interfacing and Hierarchy questions
GATE 2022 CS Q24– Let WB and WT be two set associative cache organizations that use LRU algorithm for cache…
GATE 2022 CS Q33– A cache memory that has a hit rate of 0.8 has an access latency 10 ns and miss penalty 100…
GATE 2022 CS Q54– Consider a system with 2 KB direct mapped data cache with a block size of 64 bytes. The…
GATE 2021 CS (CS1) Q32– Consider a computer system with a byte-addressable primary memory of size 232 bytes.…
GATE 2020 CS Q30– If there are m input lines and n output lines for a decoder that is used to uniquely…
GATE 2020 CS Q31– A direct mapped cache memory of 1 MB has a block size of 256 bytes. The cache has an…