linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Roman Gushchin <guro@fb.com>
To: Johannes Weiner <hannes@cmpxchg.org>
Cc: Roman Gushchin <guroan@gmail.com>,
	"linux-mm@kvack.org" <linux-mm@kvack.org>,
	Kernel Team <Kernel-team@fb.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Tejun Heo <tj@kernel.org>, Rik van Riel <riel@surriel.com>,
	Michal Hocko <mhocko@kernel.org>
Subject: Re: [PATCH v2 5/6] mm: flush memcg percpu stats and events before releasing
Date: Wed, 13 Mar 2019 18:23:09 +0000	[thread overview]
Message-ID: <20190313182301.GA7336@castle.DHCP.thefacebook.com> (raw)
In-Reply-To: <20190313160017.GA31891@cmpxchg.org>

On Wed, Mar 13, 2019 at 12:00:17PM -0400, Johannes Weiner wrote:
> On Tue, Mar 12, 2019 at 03:34:02PM -0700, Roman Gushchin wrote:
> > Flush percpu stats and events data to corresponding before releasing
> > percpu memory.
> > 
> > Although per-cpu stats are never exactly precise, dropping them on
> > floor regularly may lead to an accumulation of an error. So, it's
> > safer to flush them before releasing.
> > 
> > To minimize the number of atomic updates, let's sum all stats/events
> > on all cpus locally, and then make a single update per entry.
> > 
> > Signed-off-by: Roman Gushchin <guro@fb.com>
> 
> Acked-by: Johannes Weiner <hannes@cmpxchg.org>
> 
> Do you mind merging 6/6 into this one? That would make it easier to
> verify that the code added in this patch and the code removed in 6/6
> are indeed functionally equivalent.
> 

I did try, but the result is the mess of added and removed lines,
which are *almost* the same, but are slightly different (e.g. tabs).
So it's much easier to review it as two separate patches.

Thanks!


  reply	other threads:[~2019-03-13 18:25 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-12 22:33 [PATCH v2 0/6] mm: reduce the memory footprint of dying memory cgroups Roman Gushchin
2019-03-12 22:33 ` [PATCH v2 1/6] mm: prepare to premature release of memcg->vmstats_percpu Roman Gushchin
2019-03-12 22:33 ` [PATCH v2 2/6] mm: prepare to premature release of per-node lruvec_stat_cpu Roman Gushchin
2019-03-12 22:34 ` [PATCH v2 3/6] mm: release memcg percpu data prematurely Roman Gushchin
2019-03-12 22:34 ` [PATCH v2 4/6] mm: release per-node " Roman Gushchin
2019-03-12 22:34 ` [PATCH v2 5/6] mm: flush memcg percpu stats and events before releasing Roman Gushchin
2019-03-13 16:00   ` Johannes Weiner
2019-03-13 18:23     ` Roman Gushchin [this message]
2019-03-12 22:34 ` [PATCH 5/5] mm: spill " Roman Gushchin
2019-03-12 22:34 ` [PATCH v2 6/6] mm: refactor memcg_hotplug_cpu_dead() to use memcg_flush_offline_percpu() Roman Gushchin
2019-03-13 16:07   ` Johannes Weiner
2019-03-13 18:23     ` Roman Gushchin

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=20190313182301.GA7336@castle.DHCP.thefacebook.com \
    --to=guro@fb.com \
    --cc=Kernel-team@fb.com \
    --cc=guroan@gmail.com \
    --cc=hannes@cmpxchg.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mhocko@kernel.org \
    --cc=riel@surriel.com \
    --cc=tj@kernel.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