linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Balbir Singh <bsingharora@gmail.com>
To: Gavin Shan <gwshan@linux.vnet.ibm.com>
Cc: Balbir Singh <bsingharora@gmail.com>, linuxppc-dev@lists.ozlabs.org
Subject: Re: [PATCH] powerpc/mm: Fix RECLAIM_DISTANCE
Date: Fri, 27 Jan 2017 18:19:10 +0530	[thread overview]
Message-ID: <20170127124910.GA2668@localhost.localdomain> (raw)
In-Reply-To: <20170125045822.GA10566@gwshan>

On Wed, Jan 25, 2017 at 03:58:22PM +1100, Gavin Shan wrote:
> On Wed, Jan 25, 2017 at 09:27:44AM +0530, Balbir Singh wrote:
> >On Tue, Jan 24, 2017 at 10:32:28AM +1100, Gavin Shan wrote:
> >> When @node_reclaim_mode ("/proc/sys/vm/zone_reclaim_mode") is enabled,
> >> the nodes in the specified distance (< RECLAIM_DISTANCE) to the preferred
> >> one will be checked for page direct reclaim in the fast path, as below
> >> function call chain indicates. Currently, RECLAIM_DISTANCE is set to 10,
> >> equal to LOCAL_DISTANCE. It means no nodes, including the preferred one,
> >> don't match the conditions. So no nodes are checked for direct reclaim
> >> in the fast path.
> >> 
> >>    __alloc_pages_nodemask
> >>    get_page_from_freelist
> >>    zone_allows_reclaim
> >> 
> >> This fixes it by setting RECLAIM_DISTANCE to 30. With it, the preferred
> >> node and its directly adjacent nodes will be checked for page direct
> >> reclaim. The comments explaining RECLAIM_DISTANCE is out of date. This
> >> updates and makes it correct.
> >> 
> >> Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com>
> >> ---
> >
> >I spoke about this at length with Anton and the larger kernel team.
> >We need performance data before we can commit to the change. Do we
> >benchmarks to show that the change does not introduce regression
> >w.r.t runtime cost?
> >
> 
> Thanks for review. I just found the problem when studying the code
> last year. It sounds reasonable not to rely on the slow path for page
> reclaim if the fast path can reclaim enough pages. From this point,
> I believe the performance should be improved. In the meanwhile, the
> page cache/buffer could be released, as part of the output of page
> reclaim. It's going to affect fs's performance for sure. So do you
> have recommended test examples to measure the improved performance
> because of this?
>

Anton suggested that NUMA distances in powerpc mattered and hurted
performance without this setting. We need to validate to see if this
is still true. A simple way to start would be benchmarking

Balbir Singh.

  reply	other threads:[~2017-01-27 12:49 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-23 23:32 [PATCH] powerpc/mm: Fix RECLAIM_DISTANCE Gavin Shan
2017-01-25  3:57 ` Balbir Singh
2017-01-25  4:58   ` Gavin Shan
2017-01-27 12:49     ` Balbir Singh [this message]
2017-01-30  1:02       ` Anton Blanchard
2017-01-30  4:38         ` Gavin Shan
2017-01-30 21:11           ` Michael Ellerman
2017-01-31  5:01             ` Gavin Shan
2017-01-31  5:40               ` Gavin Shan
2017-02-07 23:40               ` Gavin Shan
2017-01-31  4:33         ` Gavin Shan
2017-01-31  4:58           ` Anton Blanchard
2017-01-31  5:30             ` Gavin Shan

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=20170127124910.GA2668@localhost.localdomain \
    --to=bsingharora@gmail.com \
    --cc=gwshan@linux.vnet.ibm.com \
    --cc=linuxppc-dev@lists.ozlabs.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).