On Fri 24 Apr 2015 02:37:21 PM CEST, Stefan Hajnoczi wrote:

>> I think it would be nice to have a way to free unused cache entries
>> after a while.
>
> Do you think mmap plus a periodic timer would work?
>
> I'm hesitant about changes like this because they make QEMU more
> complex, slow down the guest, and make the memory footprint volatile.
> But if a simple solution addresses the problem, then I'd be happy.

I understand. One possible approach would be to use the timer only if
the cache size requested by the user is large, so

 1) we only try to save memory when the amount of memory to save is
    significant.
 2) we don't make the default scenario slower.

I'll try to see if I can come up with a good solution (and with more
numbers).

Berto

Reply via email to