[linux-mm-cc] First experience of compressed cache

Nai Xia nai.xia at gmail.com
Mon Mar 31 13:17:14 EDT 2008


On Mon, Mar 31, 2008 at 11:59 PM, Baghdadi Riyadh <baghdadi13 at gmail.com> wrote:
> Hi,
>
>
> >My crazy little naive intuition tells me that MAYBE we will get much more
> if
> >we can patch the core algorithms like page aging or swapping, etc.
> >I think I can understand your points, my suggestion is just CRAZY, ha :)
>
> :)
>
> If the kernel is patched, the CompCache will take along time to get into the
> kernel mainLine,
>
>
> >>  I get from the paper "Adaptive Compressed Caching: Design and
> Implementation"
>
> >I understand that compcache-0.3 is not adaptive, unfortunately.
> Making  the CompCache adaptive is very important, but the challenge is :
> What is the policy that can be used to determine when the CompCache should
> expand (grow) or when it should be completely deactivated,
>  Nitin proposed in the old TODO list of the Ccache project to use the Dorigo
> Adaptive policy, introduced in his paper : "Adaptive Compressed Caching:
> Design and Implementation", or any other policy that can help,
>
> first issue with the current implementation of the CompCache is that it is
> implemented as ordinary swap space that (I think) cannot easily change it's
> size, (original swap partitions were not designed to enable resizing while
> they are being used), of course, this can be done if we patch the kernel
> (and export some structures and functions),
>  One possible sollution (if you find a better one please tell me :) ) is to
> create new ramswap partitions (ramswap1, ramswap2...) whenever the system

Yeah, that seems to me a good shortcut to the "resizing" problem.
P.S. A somewhat stupid question:
Is it possible that the page frames allocated for one ramswap got swap
to another ramswap?
If so, it's a harmful recursion.
( I really need to read the code for the next two weeks :) )

> needs to expand the size of the CompCache, and delete them whenever they are
> not needed,
>  this is easy to do, (I implemented that) and I now use many partitions
> (when I feel that it's necessary to add new partitions), but of course
> creating a new ramswap means that we loose one complete page that will be
> used as swap header, and also we cant add too much partitions since the
> maximum allowed number of swap partitions (as I think) is 32, so we can't
> expand it too much,
>
> so if you have another way to resize the compCache it would be great :)
>
> John used the CompCache on Ubuntu LiveCd with (I think) 90% of RAM and
> results seem to be great :)
>  I use compcache on my desktop with 256MB and compcache with 50% of RAM and
> results are also good, sometimes when I feel that system needs more RAMswap
> I just add one other partiotion (the code is not very stable)
>
> Best regards,

Best regards,

Nai


More information about the linux-mm-cc mailing list