Re: An idea for prefetching swapped memory...

From: Jörn Engel (joern@wohnheim.fh-wedel.de)
Date: Mon Apr 07 2003 - 07:43:12 EST


On Mon, 7 April 2003 14:32:26 +0200, David Zaffiro wrote:
>
> >The idea was about prefetching swapped out pages when some memory is free,
> >the CPU is idle and the I/O load is low.
> >
> >So this should not 'cost' much but behave better on following situation:
> >(I think there are even more such situations, this one should just be an
> >example)
>
> Wouldn't it cost almost twice as much when the user requests a different
> task, instead of the just swaped-in "last swaped-out task(s)"?!
>
> Instead of loading this directly into a free portion of phys. memory, the
> just-swapped-in-ex-swapped-out task(s) would need to be swapped-out *again*
> in favour of the to-be-swaped-in task...
>
> Or am I wrong here?

Partially. If done right, the swapout would simply free those pages.
The information is already on the disk and unchanged, after all.

Jörn

-- 
If you're willing to restrict the flexibility of your approach,
you can almost always do something better.
-- John Carmack
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Mon Apr 07 2003 - 22:00:31 EST