linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Yu Zhao <yuzhao@google.com>
To: linux-mm@kvack.org
Cc: Sonny Rao <sonnyrao@google.com>, Jann Horn <jannh@google.com>,
	Matthew Wilcox <willy@infradead.org>,
	Jesse Barnes <jsbarnes@google.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	page-reclaim@google.com
Subject: Re: [page-reclaim] Augmented Page Reclaim
Date: Wed, 10 Feb 2021 00:12:38 -0700	[thread overview]
Message-ID: <YCOHZhJKr6DzFQGi@google.com> (raw)
In-Reply-To: <CAJmaN=miDwb4CvVDmLS4aBKsNOVp9XiDKB1Dp3s6cfrq4yXiQQ@mail.gmail.com>

On Tue, Feb 09, 2021 at 01:32:58PM -0800, Jesse Barnes wrote:
> > ======================
> > Augmented Page Reclaim
> > ======================
> > We would like to share a work with you and see if there is enough
> > interest to warrant a run for the mainline. This work is a part of
> > result from a decade of research and experimentation in memory
> > overcommit at Google: an augmented page reclaim that, in our
> > experience, is performant, versatile and, more importantly, simple.
> 
> Per discussion on IRC, maybe some additional background would help.

And I'll add more details to the doc included in the tree once I've
finished collecting feedback.

> In looking at browser workloads on Chrome OS, we found that reclaim was:
> 1) too expensive in terms of CPU usage

We have two general metrics for this item: CPU time spent on page
reclaim and (direct) page reclaim latency. CPU usage is important to
everybody but latency is also quite important for phones, laptops,
etc.

> 2) often making poor decisions about what to reclaim

We have another two metrics here: the number of refaults and the
number of false inactive pages. For example, it's bad if pages refault
within a hundred of milliseconds after they have been reclaimed. Also
it's bad if reclaim thinks many pages are inactive but later finds
they are actually active.

> This work was mainly targeted toward improving those things, with an
> eye toward interactive performance for browser workloads.
> 
> We have a few key tests we use for that, that measure tab switch times
> and number of tab discards when under memory pressure, and this
> approach significantly improves these (see Yu's data).

We monitor workload-specific metrics as well. For example, we found
page reclaim also affects battery life, tab switch latency and the
number of janks (pauses when scrolling web pages) on Chrome OS. I
don't want to dump everything here because they seem irrelevant to
most people.

> We do expect this approach will also be beneficial to cloud workloads,
> and so are looking for people to try it out in their environments with
> their favorite key tests or workloads.

And if you are interested in our workload-specific metrics, Android,
Cloud, etc., please feel free to contact us. Any other questions,
concerns and suggestions are also welcome.

  reply	other threads:[~2021-02-10  7:13 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-02  8:57 Augmented Page Reclaim Yu Zhao
2021-02-02 12:17 ` Matthew Wilcox
2021-02-02 19:38   ` Yu Zhao
2021-02-09 21:32 ` [page-reclaim] " Jesse Barnes
2021-02-10  7:12   ` Yu Zhao [this message]
2021-02-10 13:22     ` Michal Hocko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YCOHZhJKr6DzFQGi@google.com \
    --to=yuzhao@google.com \
    --cc=jannh@google.com \
    --cc=jsbarnes@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=page-reclaim@google.com \
    --cc=sonnyrao@google.com \
    --cc=willy@infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).