Multi-level page tables, Operating System

Assignment Help:

Multi-level page tables are tree-like structures to hold page tables. As an example, consider a two- level page table, again on a 32-bit architecture with 212 = 4 kbyte pages. Now, we can divide the virtual address into three parts: say 10 bits for the level-0 index, 10 bits for the level-1 index, and again 12 bits for the offset within a page.

The entries of the level-0 page table are pointers to a level-1 page table, and the entries of the level-1 page table are PTEs as described above in the single-level page table section. Note that on a 32-bit architecture, pointers are 4 bytes (32 bits), and PTEs are typically 4 bytes.

So, if we have one valid page in our process, now our two-level page table only consumes (210

level-0 entries)(22
bytes/entry)+1(210
level-1 entries)(22
bytes/entry) = 2212
bytes = 8 kbytes:

For processes with sparse virtual memory maps, this is clearly a huge savings, made possible by the additional layer of indirection.

Note that for a process which uses its full memory map, that this two-level page table would use slightly more memory than the single-level page table (4k+4M versus 4M). The worst-case memory usage, in terms of ef?ciency, is when all 210 level-1 page tables are required, but each one only has a single valid entry.

In practice, most page tables are 3-level or 4-level tables. The size of the indices for the different levels are optimized empirically by the hardware designers, then these sizes are permanently set in hardware for a given architecture.


Related Discussions:- Multi-level page tables

Explain about demand paging, Explain about demand paging? A demand pagi...

Explain about demand paging? A demand paging system is same to a paging system with swapping. Processes reside on secondary memory. When we require executing a process, we chan

Explain lru approximation page replacement in detail, LRU approximation pag...

LRU approximation page replacement In this we utilize the reference bit associated with the page entry to choose a page to be removed. The various algorithms used for the imp

Protection, Can you please explain in easy words how input output protectio...

Can you please explain in easy words how input output protection works

Define jobs which are admitted to the system for processing, Define the Job...

Define the Jobs which are admitted to the system for processing is called The Jobs which are admitted to the system for processing is known as long-term scheduling.

What is meant by context switch, What is meant by context switch? Switc...

What is meant by context switch? Switching the CPU to another process needs saving the state of the old process and loading the saved state for the latest process. This task is

Network operating system, what is network operating? explain about it desig...

what is network operating? explain about it design issues?

Define properties of distributed operating system, Define properties of Dis...

Define properties of Distributed operating system Distributed:- This system distributes computation among several physical processors. The processors do not share memory or a

Different levels of a multilevel queuing system, Q. What merit is there in ...

Q. What merit is there in having different time-quantum sizes on different levels of a multilevel queuing system? Answer: Processes that require more frequent servicing for ins

What is an i/o subsystem?, What is an I/O subsystem? The control of dev...

What is an I/O subsystem? The control of devices connected to the computer is a main issue while designing operating systems. Since I/O devices differ widely in their function

Beladys anomaly algorithm, Q.  You have devised a fresh page-replacement a...

Q.  You have devised a fresh page-replacement algorithm that you think may be optimal. In a few contorted test cases Belady's anomaly occurs. Is the fresh algorithm optimal? Descr

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd