Home › Previous year questions › GATE 2025 CS (CS1) › Question 36GATE 2025 CS (CS1) – Question 36 Computer Organization and Architecture · Memory Interfacing and Hierarchy · 2 marks · Multiple choice
Consider a memory system with 1M bytes of main memory and 16K bytes of cache memory. Assume that the processor generates 20-bit memory address, and the cache block size is 16 bytes. If the cache uses direct mapping, how many bits will be required to store all the tag values? [Assume memory is byte addressable, 1K=$2^{10}$, 1M=$2^{20}$.]
$6 \times 2^{10}$ $8 \times 2^{10}$ $2^{12}$ $2^{14}$ Practise this question in The GATE Grind →
Show answer and explanation Correct answer: (A) $6 \times 2^{10}$
Explanation Direct-mapped cache, byte-addressable memory, 20-bit addresses.
Block size $16=2^4$ bytes, so the **offset** is 4 bits. Number of cache lines $=\dfrac{16\text{ KB}}{16\text{ B}}=\dfrac{2^{14}}{2^4}=2^{10}=1024$, so the **index** is 10 bits. **Tag** $=20-10-4=6$ bits. Each of the 1024 lines stores a 6-bit tag, so the total tag storage is $6\times2^{10}$ bits: option (A).
More Memory Interfacing and Hierarchy questions GATE 2025 CS (CS1) Q53 – A computer has a memory hierarchy consisting of two-level cache (L1 and L2) and a main… GATE 2025 CS (CS2) Q55 – Given a computing system with two levels of cache (L1 and L2) and a main memory. The first… GATE 2024 CS (CS1) Q53 – Consider two set-associative cache architectures: WBC (write back policy) and WTC (write… GATE 2024 CS (CS1) Q54 – Consider a 512 GB hard disk with 32 storage surfaces. There are 4096 sectors per track and… GATE 2024 CS (CS1) Q56 – A given program has 25% load/store instructions. The ideal CPI without memory stalls is 2.… GATE 2024 CS (CS2) Q53 – Consider a disk with rotation speed of 6000 RPM, average seek time of 5 milliseconds, 500… All Memory Interfacing and Hierarchy questions →