Re: [RFC][PATCH] ZERO PAGE again
From: KAMEZAWA Hiroyuki
Date: Thu Jul 02 2009 - 02:44:26 EST
On Wed, 01 Jul 2009 18:45:10 +0300
Avi Kivity <avi@xxxxxxxxxx> wrote:
> On 07/01/2009 12:57 PM, KAMEZAWA Hiroyuki wrote:
> > ZERO PAGE was removed in 2.6.24 (=> http://lkml.org/lkml/2007/10/9/112)
> > and I had no objections.
> >
> > In these days, at user support jobs, I noticed a few of customers
> > are making use of ZERO_PAGE intentionally...brutal mmap and scan, etc. They are
> > using RHEL4-5(before 2.6.18) then they don't notice that ZERO_PAGE
> > is gone, yet.
> > yes, I can say "ZERO PAGE is gone" to them in next generation distro.
> >
> > Recently, a question comes to lkml (http://lkml.org/lkml/2009/6/4/383
> >
> > Maybe there are some users of ZERO_PAGE other than my customers.
> > So, can't we use ZERO_PAGE again ?
> >
> > IIUC, the problem of ZERO_PAGE was
> > - reference count cache ping-pong
> > - complicated handling.
> > - the behavior page-fault-twice can make applications slow.
> >
> > This patch is a trial to de-refcounted ZERO_PAGE.
> > Any comments are welcome. I'm sorry for digging grave...
> >
>
> kvm could use this. There's a fairly involved scenario where the lack
> of zero page hits us:
>
> - a guest is started
> - either it doesn't touch all of its memory, or it balloons some of its
> memory away, so its resident set size is smaller than the total amount
> of memory it has
> - the guest is live migrated to another host; this involves reading all
> of the guest memory
>
> If we don't have zero page, all of the not-present pages are faulted in
> and the resident set size increases; this increases memory pressure,
> which is what we're trying to avoid (one of the reasons to live migrate
> is to free memory).
>
Thank you. I'll make this patch cleaner and fix my English, then post again.
maybe in the next week.
A case I met was the application level migration. An application save its
sparse table by scan-and-dump. To know "all memory contents are zero",
it had to read memory, at least.
Regards,
-Kame
> --
> error compiling committee.c: too many arguments to function
>
--
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/