linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michal Hocko <mhocko@kernel.org>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Tim Murray <timmurray@google.com>,
	Sonny Rao <sonnyrao@chromium.org>,
	Daniel Colascione <dancol@google.com>,
	Minchan Kim <minchan@kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Joel Fernandes <joelaf@google.com>,
	Al Viro <viro@zeniv.linux.org.uk>,
	linux-fsdevel@vger.kernel.org, Linux-MM <linux-mm@kvack.org>,
	Robert Foss <robert.foss@collabora.com>,
	linux-api@vger.kernel.org, Luigi Semenzato <semenzato@google.com>
Subject: Re: [PATCH RFC v2] Add /proc/pid/smaps_rollup
Date: Mon, 28 Aug 2017 13:30:23 +0200	[thread overview]
Message-ID: <20170828113023.GH17097@dhcp22.suse.cz> (raw)
In-Reply-To: <20170825141637.f11a36a9997b4b705d5b6481@linux-foundation.org>

On Fri 25-08-17 14:16:37, Andrew Morton wrote:
> On Thu, 24 Aug 2017 10:55:53 +0200 Michal Hocko <mhocko@kernel.org> wrote:
> 
> > > If we assume that the number of VMAs is going to increase over time,
> > > then doing anything we can do to reduce the overhead of each VMA
> > > during PSS collection seems like the right way to go, and that means
> > > outputting an aggregate statistic (to avoid whatever overhead there is
> > > per line in writing smaps and in reading each line from userspace).
> > > 
> > > Also, Dan sent me some numbers from his benchmark measuring PSS on
> > > system_server (the big Android process) using smaps vs smaps_rollup:
> > > 
> > > using smaps:
> > > iterations:1000 pid:1163 pss:220023808
> > >  0m29.46s real 0m08.28s user 0m20.98s system
> > > 
> > > using smaps_rollup:
> > > iterations:1000 pid:1163 pss:220702720
> > >  0m04.39s real 0m00.03s user 0m04.31s system
> > 
> > I would assume we would do all we can to reduce this kernel->user
> > overhead first before considering a new user visible file. I haven't
> > seen any attempts except from the low hanging fruid I have tried.
> 
> It's hard to believe that we'll get anything like a 5x speedup via
> optimization of the existing code?

Maybe we will not get that much of a boost but having misleading numbers
really quick is not something we should aim for. Just try to think what
the cumulative numbers actually mean. How can you even consider
cumulative PSS when you have no idea about mappings that were
considered?

-- 
Michal Hocko
SUSE Labs

  reply	other threads:[~2017-08-28 11:30 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-08 13:25 [PATCH] Add /proc/pid/smaps_rollup Daniel Colascione
2017-08-08 18:22 ` Daniel Colascione
2017-08-08 18:42   ` Greg KH
2017-08-08 18:51     ` Daniel Colascione
2017-08-08 18:56       ` Greg KH
2017-08-10  0:15 ` [PATCH RFC v2] " Daniel Colascione
2017-08-10  1:24   ` Randy Dunlap
2017-08-10  4:38   ` Minchan Kim
2017-08-10  8:46     ` Michal Hocko
2017-08-10 10:23       ` Daniel Colascione
2017-08-10 10:58         ` Michal Hocko
2017-08-10 18:56           ` Sonny Rao
2017-08-10 19:17             ` Tim Murray
2017-08-24  8:55               ` Michal Hocko
2017-08-25 21:16                 ` Andrew Morton
2017-08-28 11:30                   ` Michal Hocko [this message]
2017-08-12  2:21   ` [PATCH v3] " Daniel Colascione

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=20170828113023.GH17097@dhcp22.suse.cz \
    --to=mhocko@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=dancol@google.com \
    --cc=joelaf@google.com \
    --cc=linux-api@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=minchan@kernel.org \
    --cc=robert.foss@collabora.com \
    --cc=semenzato@google.com \
    --cc=sonnyrao@chromium.org \
    --cc=timmurray@google.com \
    --cc=viro@zeniv.linux.org.uk \
    /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).