• edited by
21,688 views
57 57 votes

A multilevel page table is preferred in comparison to a single level page table for translating virtual address to physical address because

  1. It reduces the memory access time to read or write a memory location.

  2. It helps to reduce the size of page table needed to implement the virtual address space of a process

  3. It is required by the translation lookaside buffer.

  4. It helps to reduce the number of page faults in page replacement algorithms.

8 Answers

Best answer
70 70 votes

Option - > (B)

  1. It reduces the memory access time to read or write a memory location. -> No This is false. Actually because of multi level paging we increase no of memory accesses.

  2. It helps to reduce the size of page table needed to implement the virtual address space of a process -> This is true, In case of big virtual memory , size of single level page table will be more compared to size of multilevel page table . 

  3. It is required by the translation lookaside buffer.-> Examiner was not being enough creative here, This is false & There is no relation. This option is just given for no reason !

  4. It helps to reduce the number of page faults in page replacement algorithms.-> This is false, we might increase no of page faults. (Due to second / third level page not in memory here !) So this is false.

• edited by
16 16 votes
B.

Which is a clear reason why we perform paging.

When the page table size increases we perform paging on the page table. Resulting in multi-level page table.
12 12 votes

A.   This is false.  Because in multi level paging we increase number of memory accesses depending upon number of levels of Page tables. Since to access each level you need 1 memory access.


B. This is true, In case of most of the programs most of the space is empty and they only utilize a small portion of the memory that is reserved in Main memory which causes lots of invalid entries in Page Table which in-turn increase the Page Table Size.

Lets Take an Example-

Consider,

Page Size = 4 KB.

PTE = 8 Bytes,

VAS = $2^{^{32}}$Bytes.

Then Size of Page Table = 8MB.

If a process only need Lets say, 20 Pages in Main memory then Only 20 entries are valid in Page Table equivalent to 20*8 = 160 Bytes. Rest all the space is invalid. Idea of Multi Level Paging is to not store these invalid entries (or at least reduce) and hence more levels are made which points to each chunk in the default Page table(page table directly pointing to main memory) and only stores the valid chunks in the main memory .

Then total space in the main memory = Size of second level page table + Size of valid chunks(chunks containing valid entries) in default page table . This reduces a lot space. Similarly More levels can be introduced to further reduce space. Trade-off is access time and Page Faults.

NOTE: MULTILEVEL PAGING IS NOT FORCED. WE HAVE NO NEED TO FIT PAGE TABLE IN ONE PAGE, WE CAN SIMPLY OCCUPY MORE PAGES. 

C. This is false since there is no relation of TLB with MLP. 


D. This is false, since more lower level pages will cause more page faults due to absence of more and more Default Page table entries which program might need further(as stack and heap size grows).

 


If you liked the answer, Please Drop a  ⬆ UPVOTE

• edited by
2 2 votes

(A) In multi level page table we have to go through multiple page tables instead of only one in single level page table. So it actually increases the memory access time. This is False.

(B) In multi level paging we can avoid saving invalid or unused entries in the respectively lower levels and the physical memory itself but in case of single level paging we do not have any other option than storing all the entries. This is True

(C) This option is unrelated and False.

(D) This may increase the number of page faults because of the absence of higher level pages are not in the memory.

1 1 vote
In a single-level page table, there is one entry for every virtual page. Therefore, for a large virtual address space, the page table can become very large. Moreover, the complete page table has to be allocated even if large portions of the virtual address space are unused.

In multilevel paging, the page table is divided into multiple levels. The lower-level page tables are created only for those portions of the virtual address space that are actually required. Therefore, page-table entries for unused or unallocated portions do not need to be stored.

For example, if a process uses only a small portion of a very large virtual address space, multilevel paging can avoid allocating page-table structures for the unused portions. Hence, the actual memory required for the page tables can be significantly reduced.

Therefore, option (B) is correct: multilevel paging helps reduce the size of the page table needed to implement the virtual address space of a process.
ago
0 0 votes

Correct Answer Option B Because,....

EXAMPLE : 

Q) A proess having 32 bit VAS and a page size of 4KB and using only 2^16 Bytes 

1)with single level paging:

then with a single level paging the size of page table will be 2^20*2^2=4MB 

2)with multilevel paging:

if we use multilevel paging the size of the page table can be reduced to 8KB (since,the pages are stored from address 0 i.e together at one place )

VAS :

101012

No of pages in the process = 2^20 pages

No,, of useful pages = 2^16/2^12 = 2^4 = 16 pages 

so,at first level page table only 16 entries are useful

all these can be grouped to one chunk of size 2^10 entries in first level PT

so, at second level page table the no,, of useful entries will be only one 

since,we are dealing with chunks...

i.e 1*2^10+1*2^10 = 8KB

Here we can clearly see that the multilvel paging reducing the size of page table as compared to single level paging right.

so,multilevel paging always helps to reduce the size of page table needed to implement the virtual address space of a process is true but, it doesn't mean that multilevel paging is forced to reduce the size of page table we can stop at any level i.e,it is a big misconception that  if the page table size is 4MB and page size is 4KB that's why we use multilevel paging to fit that page table in the availble page space.why we even want to fit in one page we can span over the other pages and even if the size of the page table is fit enough with the page size we can still use multilevel paging to reduce the page table size and to save memory.here everything is our choice i.e we have divided the VAS in to 10 | 10 | 12 but if we want we can leave it without dividing further 20 | 12 .although the process size is too small and page table size is too big we are just trying to reduce size of page table and store with few memory.

• edited by
Answer:
Position:
Show:

Related questions

52 52 votes
2 answers 2 answers
19.8k
19.8k views
Kathleen asked Sep 22, 2014
19,822 views
The essential content(s) in each entry of a page table is / areVirtual page numberPage frame numberBoth virtual page number and page frame numberAccess right information
33 33 votes
6 answers 6 answers
13.9k
13.9k views
Kathleen asked Sep 22, 2014
13,917 views
In which one of the following page replacement policies, Belady's anomaly may occur?FIFOOptimalLRUMRU
36 36 votes
3 answers 3 answers
18.5k
18.5k views
Kathleen asked Sep 22, 2014
18,539 views
Consider a binary max-heap implemented using an array.Which one of the following array represents a binary max-heap?$\left\{25,12,16,13,10,8,14\right\}$ $\left\{25,14,...
5 5 votes
1 1 answer
7.2k
7.2k views
Kathleen asked Sep 22, 2014
7,179 views
Consider the following statements about the cyclomatic complexity of the control flow graph of a program module. Which of these are TRUE? The cyclomatic complexity of a m...