Skip to content
Official PYQ · 2019

GATE CS 2019 Q33 — Memory Management and Virtual Memory

Explain with AI

Assume that in a certain computer, the virtual addresses are 6464 bits long and the physical addresses are 4848 bits long. The memory is word addressible. The page size is 88 kB and the word size is 44 bytes. The Translation Look-aside Buffer (TLB) in the address translation path has 128128 valid entries. At most how many distinct virtual addresses can be translated without any TLB miss?

Choose one option
View worked solution

Answer: B

To find the maximum number of distinct virtual addresses that can be translated without a TLB miss, we need to determine how many addressable units (words) can be mapped by the TLB entries simultaneously.

Step 1: Calculate the number of addresses per page

We are given:

  • Memory addressing: Word-addressable
  • Word size: 4 bytes4\text{ bytes}
  • Page size: 8 kB=8×1024 bytes=8192 bytes8\text{ kB} = 8 \times 1024\text{ bytes} = 8192\text{ bytes}

Since the memory is word-addressable, each distinct address refers to one word. Therefore, the number of distinct virtual addresses (words) in a single page is:

Addresses per page=Page sizeWord size=8192 bytes4 bytes=2048 words=211 words\text{Addresses per page} = \frac{\text{Page size}}{\text{Word size}} = \frac{8192\text{ bytes}}{4\text{ bytes}} = 2048\text{ words} = 2^{11}\text{ words}

Step 2: Calculate the total addresses mapped by the TLB

The TLB has 128=27128 = 2^7 valid entries. Each entry maps exactly one virtual page to a physical page frame.

Thus, the maximum number of distinct virtual addresses that can be translated without a TLB miss is:

Total Addresses=Number of TLB entries×Addresses per page\text{Total Addresses} = \text{Number of TLB entries} \times \text{Addresses per page} Total Addresses=128×211=27×211=218\text{Total Addresses} = 128 \times 2^{11} = 2^7 \times 2^{11} = 2^{18}

Step 3: Match with the options

Let's simplify the options to find the match for 2182^{18}:

  • Option A: 16×210=24×210=21416 \times 2^{10} = 2^4 \times 2^{10} = 2^{14}
  • Option B: 256×210=28×210=218256 \times 2^{10} = 2^8 \times 2^{10} = 2^{18}
  • Option C: 4×220=22×220=2224 \times 2^{20} = 2^2 \times 2^{20} = 2^{22}
  • Option D: 8×220=23×220=2238 \times 2^{20} = 2^3 \times 2^{20} = 2^{23}

This matches Option B.

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

Published
Report a correction
Keep exploringMore Memory Management and Virtual Memory questions