Re: [PATCH][RF C/T/D] Unmapped page cache control - via bootparameter
From: Balbir Singh
Date: Mon Mar 15 2010 - 06:46:10 EST
* Avi Kivity <avi@xxxxxxxxxx> [2010-03-15 11:27:56]:
> >>>The knobs are for
> >>>
> >>>1. Selective enablement
> >>>2. Selective control of the % of unmapped pages
> >>An alternative path is to enable KSM for page cache. Then we have
> >>direct read-only guest access to host page cache, without any guest
> >>modifications required. That will be pretty difficult to achieve
> >>though - will need a readonly bit in the page cache radix tree, and
> >>teach all paths to honour it.
> >>
> >Yes, it is, I've taken a quick look. I am not sure if de-duplication
> >would be the best approach, may be dropping the page in the page cache
> >might be a good first step. Data consistency would be much easier to
> >maintain that way, as long as the guest is not writing frequently to
> >that page, we don't need the page cache in the host.
>
> Trimming the host page cache should happen automatically under
> pressure. Since the page is cached by the guest, it won't be
> re-read, so the host page is not frequently used and then dropped.
>
Yes, agreed, but dropping is easier than tagging cache as read-only
and getting everybody to understand read-only cached pages.
--
Three Cheers,
Balbir
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/