lkml.org 
[lkml]   [1996]   [May]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRE: Swapping algorithm

> ________________________________________________________
> To: 92jjb@eng.cam.ac.uk@INTERNET
> Cc: davem@caip.rutgers.edu@INTERNET; jamie@rebellion.co.uk@INTERNET;
linux-kernel@morticia.physics.colostate.edu(RFC-822)@INTERNET
> From: Hemment_Mark/HEMEL_IOPS_INTERNATIONAL-SALES@uniplex.co.
uk(RFC-822)@INTERNET on Thu, May 2, 1996 2:30 PM
> > Jon Burgess wrote:
> > On Tue, 23 Apr 1996, David S. Miller wrote:
> >> Date: Mon, 22 Apr 96 18:26 BST
> >> From: Jamie Lokier <jamie@rebellion.co.uk>
> >>
> >> [good idea to generate page-faults to gather usage stats]
(big snip)

> When memory becomes low, a kernel process "pagedaemon" (I think) is
> woken up. It first scans the list of "to-be-free-list", moving 'x'
> pages from the head of the list into the kernel's free-list. By
> taking from the head of the list, pages which have recently been added
> are given a chance to be reclaimed by the process(es). If free memory
> is becoming very low, then the dirty pages are written to disk and
> moved to the end of the "to-be-free-list".
>
> The "clock" is a "Not-Recently-Used" algorithm, and is not very
> difficult to implement. It can run of the kernel's soft-interrupt.
> The main difficultly is in "tuning";
> How many pages to scan each time (ie. how far to move the
> hands).
>
> markhe

In my VAX/VMS days, there were two type of page-faults:
"hard", where the page had to be read in from disk, and
"soft", where the page was still in memory (and on disk), but on the list of
pages that had been written out but not yet re-used.
As I recall, a soft-page-fault was so cheap, that they didn't worry too much
about it.

Ray


\
 
 \ /
  Last update: 2005-03-22 13:37    [W:0.042 / U:1.168 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site