Re: why swap at all?

From: Nick Piggin
Date: Thu May 27 2004 - 01:04:51 EST


Tom Felker wrote:
On Wednesday 26 May 2004 7:37 am, Matthias Schniedermeyer wrote:


program to kernel: "i read ONCE though this file caching not useful".


Very true. The system is based on the assumption that just-used pages are more useful that older pages, and it slows when this isn't true. We need ways to tell the kernel whether the assumption holds.


A streaming flag is great, but we usually do OK without it. There
is a "used once" heuristic that often gets it right as far as I
know. Basically, new pages that are only used once put almost zero
pressure on the rest of the memory.

It has a few corner cases where it breaks down. Hopefully they can
be improved...
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/