Lru implementation details, Operating System

Now, let us discuss two related algorithms for deciding which pages to evict. The clock algorithm is one of the most popular choices. It works by keeping frames in a circular structure. (Note that this circle may be very large: a 32-bit machine with 4k pages can have up to 220  1 million frames.) When a page fault occurs, it checks the reference bit of the next frame. If that bit is zero, it evicts that page and sets its bit to 1; if the reference bit is 1, the algorithm sets the bit to 0 and advances the pointer to next frame. 

An implementation which is often used in real operating systems is a segmented queue. This type of algorithm divides all existing pages into two sets of pages. The most-active one-third of all pages use a clock algorithm. After that, pages that are evicted out of the clock are moved to a "uncommon" linked list, in which we use exact LRU. This way, we approximate LRU for the frequently-referenced pages (1/3 of the page frames - fast clock algorithm), and at the same time use exact LRU on the infrequently accessed pages (2/3 of all page frames). Since the pages in the uncommon list are not accessed very frequently, it is okay if their accesses are a little slower due to some pointer manipulation.

Posted Date: 3/12/2013 6:01:10 AM | Location : United States







Related Discussions:- Lru implementation details, Assignment Help, Ask Question on Lru implementation details, Get Answer, Expert's Help, Lru implementation details Discussions

Write discussion on Lru implementation details
Your posts are moderated
Related Questions
File allocation using I nodes. This method is used to decrease the size of the table in the above method. Every file will have an I-node list. Allow a file have 15 pointers a

What are the system components of an operating system and explain them? a) Process management b) Main-memory management c) I/O management d) File management e) Seco

Explain the general structure of a typical process? There are basically four main sections through which each of the process has to pass through.The universal algorithm is:-

Define the OS/2 threads code The sample program in Listing is very similar to the NetWare example. OS/2 commands are substituted for the pseudocode commands controlling thread

UNIX Shell and History feature. 1.Creating a child process. 2.Creating a history feature. Its exactly "programming project 1 - Unix Shell and History Feature (p.157-159)" in the Si

What are the different file operations? Create : - Space for the file in the file system update directory table. Write : - file name and data to be written is

Question : a) Describe the difference between the authentication of a user account on a peer to peer network and a client server network. b) Compare an end user account with

We can view an operating system as a resource allocator. Explain. We can outlook an operating system as a resource allocator. A computer system has Many resources (software and

What is the main function of the memory-management unit? The runtime mapping from virtual to physical addresses is done by a hardware device known as a memory management unit (

Explain Terminal Symbols Terminal symbols are literal strings that are forming the input of a formal grammar and cannot be broken down into smaller units with no losing their l