Monday, August 23, 2021

Optimal Page Replacement Algorithm | What is page replacment? | Why page replacement algorithm used? | Page replacement alogirthm example | Page replacement alogirthm in COA

 

Optimal Page Replacement Algorithm

Page replacement algorithm are needed to decide which page to be replaced when new page comes in main memory. Page Fault – A page fault occurs when a program attempts to access a block of memory that is not stored in the physical memory, or RAM. Different page replacement algorithms are: FIFO, LRU, Optimal. The target for all algorithms is to reduce number of page faults.

If there is new page arrives and page frame has empty slots. Then page will be store directly in page frame. If referred page is already present, increment hit count. If not present, find if a page that is never referenced in future.  If such a page exists, replace this page with new page. If no such page exists, find a page that is referenced farthest in future. Replace this page with new page. This algorithm results in fewest number of page faults. But this algorithm is impossible to implement.



To learn more about Optimal Page Replacement Algorithm, watch below video



Video : Optical Page Replacement Algorithm

Watch more videos click here.


No comments:

Post a Comment