wacky implicit swap idea

John Labovitz (johnl@meer.net)
Sun, 12 Jul 1998 12:27:21 -0700


i was reading Rik van Riel's paper on the zone-based memory allocator
(http://www.phys.uu.nl/~riel/zone-alloc.html), and came across this
sentence:

Because of the fact that most UNIX (and Linux) machines have a
completely full memory (free memory is wasted memory), it is next
to impossible to free larger area's and the best we can do is be
very careful not to hand out those large areas when we only need a
small one.

that phrase `free memory is wasted memory' got me thinking: could that
same philosophy be applied to disk space? as it stands now, i have a
predetermined and always allocated swap partition, plus a certain
amount of free disk space that's used for absolutely nothing until i
actually save a file to it. could the MM code interact with the
filesystem driver in such a way that swapping could be done to free
blocks anywhere on the disk, rather than only free blocks in the
specific partition that's marked as swap?

i think it might be cool if a linux installation didn't have to
configure swap space; swap could just grow (or shrink) according to
the actual disk space in the system. it might be good to mark certain
disks as `swappable', so that swap would at least start out on fast
devices.

i don't know how to handle the case where a process needs to use a
disk block that's currently in use as swap (ie, disk *and* memory gets
full). oh, start using that free floppy space... ;)

john

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.altern.org/andrebalsa/doc/lkml-faq.html