Question:

A system has a Translation Lookaside Buffer (TLB) that has a reach of 1 MB. TLB
reach is defined as the total amount of physical memory that can be accessed
through the TLB entries. The paging system uses pages of size 4 KB. The virtual
address space is 64 GB and physical address space is 1 GB. If each TLB entry stores
a 4-bit process id, page number, frame number, and a 2-bit control field, then the
size of the TLB (in bytes) is ___________. (answer in integer)
Note: 1K=210, 1M=220, 1G=230

Show Hint

First use TLB reach and page size to get the number of TLB entries. Then use virtual address space and physical address space (divided by page/frame size) to get the widths of the page number and frame number fields. Add process id + page number + frame number + control bits to get one entry's size in bytes, then multiply by the number of entries.
Updated On: Jul 7, 2026
Show Solution
collegedunia
Verified By Collegedunia

Correct Answer: 1536

Solution and Explanation

We need to find the total size of the TLB in bytes, given the TLB reach, page size, virtual address space, and physical address space.

Step 1: Find the number of entries in the TLB.

TLB reach is the total physical memory addressable through the TLB, so:

\[\text{Number of TLB entries} = \frac{\text{TLB reach}}{\text{Page size}} = \frac{1\,MB}{4\,KB} = \frac{2^{20}}{2^{12}} = 2^{8} = 256\]

Step 2: Find the number of bits needed for the page number field.

Virtual address space is 64 GB and page size is 4 KB, so the number of virtual pages is:

\[\frac{64\,GB}{4\,KB} = \frac{2^{36}}{2^{12}} = 2^{24}\]

So the page number field requires 24 bits.

Step 3: Find the number of bits needed for the frame number field.

Physical address space is 1 GB and frame size is 4 KB, so the number of physical frames is:

\[\frac{1\,GB}{4\,KB} = \frac{2^{30}}{2^{12}} = 2^{18}\]

So the frame number field requires 18 bits.

Step 4: Compute the size of one TLB entry.

Each TLB entry contains a 4-bit process id, the page number field, the frame number field, and a 2-bit control field:

\[4 + 24 + 18 + 2 = 48 \text{ bits} = \frac{48}{8} = 6 \text{ bytes}\]

Step 5: Compute the total size of the TLB.

\[\text{Total TLB size} = \text{Number of entries} \times \text{Size per entry} = 256 \times 6 = 1536 \text{ bytes}\]

\[\boxed{1536 \text{ bytes}}\]

Was this answer helpful?
0
0

Top GATE CS Computer Science and IT Engineering Questions

View More Questions