Skip to content

Page replacement algorithms for memory management in operating systems

Notifications You must be signed in to change notification settings

moharamfatema/page-replacement

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 

Repository files navigation

page-replacement

Page replacement algorithms for memory management in operating systems


Pseudo code for predict algorithm

Predict(frames,sequence,it)
1    let q be a priority queue
    
2    for j = 0 to frames.size
3        i = find index of first occurence of p in sequence from it to sequence.size
4        q.insert(<i,j>)
    
5    return j from q.top (the index of the page in frames to be replaced)