FOR FREE MATERIALS

GATE 2001: Qno: 46

 

Question:

Consider a machine with 64 MB physical memory and a 32-bit virtual address space. If the page size is 4KB, what is the approximate size of the page table?


(A) 16 MB
(B) 8 MB
(C) 2 MB
(D) 24 MB

 

You should know:

Before seeing the solution please follow Calculation of offset for logical and physical address, Calculation of logical address bit and number of pages, Calculation of physical address bit and number of frames, Calculation of page table size. 

 

Solution:

 

Given data:

Physical memory = Physical Address Space (PAS) = 64MB = 226

Virtual memory = Logical Address (LA) = 32 bit, so, Logical Address Space (LAS) = 232 = 4GB

Page Size = 4KB = 212

 

So, we can calculate,

We know page size and frame size is same i.e. page size = frame size = 4KB = 212

 

And we can also calculate, 

So, number of bit in frame number in PAS= 14 bit

 

Now, Page Table Size (PTS) Number of pages × Page entry

 

Because nothing is mentioned about other bits of page entry, we always assume frame number = page entry size = 16 bit.

 

Now, in question, they asked page table size in Byte.

So, we can convert it to byte by divided by 8 (Because 1Byte = 8bit)

 

 

Note:  Sometimes questions ask approximate answers in this case carefully take the nearest one as an approximate answer.

 

So, option (C) is correct.