Virtual memory, pages, fields in page table entry

Virtual memory is a type of memory management method where virtual address space of programs are divided in to fixed size slots known as pages. A page is a contiguous range of memory addresses which is mapped to physical memory. This mapping is done by page tables in Memory Management Unit. A virtual page number is used as an index to locate a page frame number for a particular page. The slots which correspond to pages in physical memory are known as page frames. Present/absent bits are used to keep track of the pages in physical memory.

Mapping of virtual address space to physical memory

Page table entry: A typical page table entry has the following fields:

1) Page frame number: It is a number to specify a page frame in physical memory.

2) Present/absent bit: It is used for keeping a track of pages. If its value is 1, then entry is valid. If its value is 0, then, the page is not in memory and there will be a page fault if the entry is accessed.

3) Protection bits: It is used for providing the access. There are 3 bits, a bit each to control read, write and execute.

4) Modified bits: It is used for tracking if the page is modified or not.

5) Referenced bits: It is used for tracking if the page is referenced or not.

6) Disable caching: It is used for disabling the caching.

Page table entry

Leave a Reply