[linux-mm-cc] Advantages of "saving swap space".

Nitin Gupta nitingupta.mail at gmail.com
Sat May 5 07:15:11 EDT 2007


Hi,

Thanks for detailed comments on compressed swapping.

Compressed swapping is low priority thing but is certainly
good-to-have feature (esp. for embedded devices). So, I will add your
points to Todo list to make sure we don't loose track of these :)

Compressed swapping (without padding) will require very intrusive
changes to existing swapping code but is fairly independent from rest
of ccaching stuff. So, someone can pick it up without worrying much
about rest of ccaching things.

Cheers,
Nitin


On 5/5/07, John McCabe-Dansted <gmatht at gmail.com> wrote:
> "Swap-out compressed pages as-is. Delay decompression until they are
> swapped-in and really used (Purpose here is not to save swap space –
> we'll pad out compressed page with 0's when swapping-out)."
>
> Hi, I realise that there are other priorities now, but I'd like to
> suggest that there are a number of cases where writing compressed data
> to swap space without zero padding would help:
>
> * Video Ram:
>   http://hedera.linuxnews.pl/_news/2002/09/03/_long/1445.html
>
> Here, we clearly want to be able to pack as much as possible into the
> VRAM swap before having to write to HDD.
>
> * Swap Prefetch:
>   http://en.wikipedia.org/wiki/Virtual_memory
> The linux Swap Prefetch and the new Windows Vista SuperFetch features
> load pages back into memory when you have unused memory. The time
> required to do load large amounts of swap back into memory may depend
> on the efficiency of the on-disk swap format.  Likewise pre-emptively
> writing out swap in contiguous blocks may result in faster
> performance.
>
> * USB Swap:
>   http://dansdata.com/flashswap.htm
> From dansdata above, it is now reasonable to use a USB disk as swap; A
> modern USB disk should last a few years of being used as swap, by
> which time the value of the disk would be negligible anyway. However,
> if we could save write IO by writing out data in compressed format,
> this could help too.
>
>   http://www.anandtech.com/systems/showdoc.aspx?i=2917&p=6
> From anandtech above, Windows ReadyFetch for utilising USB disks can
> increase system performance on low memory systems, despite ReadyFetch
> being designed so that removing the USB disk while in use does not
> cause failure. (I guess a simple way of achieving this would be would
> be to only write clean pages to the USB swap.)
>
> --
> John C. McCabe-Dansted
> PhD Student
> University of Western Australia
> _______________________________________________
> linux-mm-cc mailing list
> linux-mm-cc at laptop.org
> http://mailman.laptop.org/mailman/listinfo/linux-mm-cc
>


More information about the linux-mm-cc mailing list