public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Rik van Riel <riel@redhat.com>
To: balbir@in.ibm.com
Cc: Andrea Arcangeli <andrea@suse.de>,
	Niki Hammler <mailinglists@nobaq.net>,
	linux-kernel@vger.kernel.org,
	Vaidyanathan Srinivasan <svaidy@linux.vnet.ibm.com>
Subject: Re: Why active list and inactive list?
Date: Mon, 22 Jan 2007 20:42:59 -0500	[thread overview]
Message-ID: <45B56823.7050104@redhat.com> (raw)
In-Reply-To: <45B56575.10807@in.ibm.com>

Balbir Singh wrote:

> This makes me wonder if it makes sense to split up the LRU into page
> cache LRU and mapped pages LRU. I see two benefits

Unlikely.  I have seen several workloads fall over because they
did not throw out mapped pages soon enough.

If the kernel does not keep the most frequently accessed pages
resident, hit rates will suffer.  Sometimes (well, usually)
those are the mapped pages, but this is not true in all workloads.

Some workloads are very page cache heavy and it pays to keep
the more frequently accessed page cache pages resident while
discarding the less frequently accessed ones.

Since memory size has increased a lot more than disk speed
over the last decade (and this is likely to continue for the
next decades), the quality of page replacement algorithms is
likely to become more and more important over time.

> 1. Currently based on swappiness, we might walk an entire list
>    searching for page cache pages or mapped pages. With these
>    lists separated, it should get easier and faster to implement
>    this scheme

How do you classify a mapped page cache page?

Another issue is that you'll want to make sure that the page
cache pages that are referenced more frequently than the least
referenced mapped (I assume you mean anonymous?) pages in
memory, while swapping out those least used anonymous pages.

One way to do this could be to compare the scan rates, list
sizes and referenced percentage of both lists, to find out
which of the two caches is hotter.

> 2. There is another parallel thread on implementing page cache
>    limits. If the lists split out, we need not scan the entire
>    list to find page cache pages to evict them.

If the lists split out, there is no reason to limit the page
cache size because you can easily reclaim them.  Right?

> Of course I might be missing something (some piece of history)

http://linux-mm.org/AdvancedPageReplacement

-- 
Politics is the struggle between those who want to make their country
the best in the world, and those who believe it already is.  Each group
calls the other unpatriotic.

  parent reply	other threads:[~2007-01-23  1:50 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-01-23  0:10 Why active list and inactive list? Niki Hammler
2007-01-23  0:39 ` Andrea Arcangeli
2007-01-23  1:31   ` Balbir Singh
2007-01-23  1:40     ` Christoph Lameter
2007-01-23  1:49       ` Rik van Riel
2007-01-23  2:03         ` Christoph Lameter
2007-01-23  2:17           ` Rik van Riel
2007-01-23  2:44             ` Christoph Lameter
2007-01-23  2:50               ` Rik van Riel
2007-01-23  8:29           ` Peter Zijlstra
2007-01-23 15:02             ` Rik van Riel
2007-01-30 11:01               ` Howard Chu
2007-01-23  3:36         ` Balbir Singh
2007-01-23  3:43           ` Christoph Lameter
2007-01-23  3:51             ` Balbir Singh
2007-01-23  3:18       ` Balbir Singh
2007-01-23  3:28         ` Christoph Lameter
2007-01-23  3:45           ` Balbir Singh
2007-01-23  3:51             ` Christoph Lameter
2007-01-23  1:42     ` Rik van Riel [this message]
2007-01-23  2:13     ` Andrea Arcangeli
2007-01-23  4:17     ` Nick Piggin
2007-01-23  4:34       ` Rik van Riel
2007-01-23  5:51         ` Balbir Singh
2007-01-23  4:46       ` Balbir Singh
     [not found] <7Gpmk-5fN-21@gated-at.bofh.it>
2007-01-30 10:23 ` Howard Chu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=45B56823.7050104@redhat.com \
    --to=riel@redhat.com \
    --cc=andrea@suse.de \
    --cc=balbir@in.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mailinglists@nobaq.net \
    --cc=svaidy@linux.vnet.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox