[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20170307144338.023080a8cd600172f37dfe16@linux-foundation.org>
Date: Tue, 7 Mar 2017 14:43:38 -0800
From: Andrew Morton <akpm@...ux-foundation.org>
To: Michal Hocko <mhocko@...nel.org>
Cc: Johannes Weiner <hannes@...xchg.org>, Shaohua Li <shli@...com>,
linux-mm@...ck.org, linux-kernel@...r.kernel.org,
Kernel-team@...com, minchan@...nel.org, hughd@...gle.com,
riel@...hat.com, mgorman@...hsingularity.net
Subject: Re: [PATCH V5 6/6] proc: show MADV_FREE pages info in smaps
On Tue, 7 Mar 2017 11:05:45 +0100 Michal Hocko <mhocko@...nel.org> wrote:
> On Fri 03-03-17 16:10:27, Andrew Morton wrote:
> > On Thu, 2 Mar 2017 17:30:54 +0100 Michal Hocko <mhocko@...nel.org> wrote:
> >
> > > > It's not that I think you're wrong: it *is* an implementation detail.
> > > > But we take a bit of incoherency from batching all over the place, so
> > > > it's a little odd to take a stand over this particular instance of it
> > > > - whether demanding that it'd be fixed, or be documented, which would
> > > > only suggest to users that this is special when it really isn't etc.
> > >
> > > I am not aware of other counter printed in smaps that would suffer from
> > > the same problem, but I haven't checked too deeply so I might be wrong.
> > >
> > > Anyway it seems that I am alone in my position so I will not insist.
> > > If we have any bug report then we can still fix it.
> >
> > A single lru_add_drain_all() right at the top level (in smaps_show()?)
> > won't kill us
>
> I do not think we want to put lru_add_drain_all cost to a random
> process reading /proc/<pid>/smaps.
Why not? It's that process which is calling for the work to be done.
> If anything the one which does the
> madvise should be doing this.
But it would be silly to do extra work in madvise() if nobody will be
reading smaps for the next two months.
How much work is it anyway? What would be the relative impact upon a
smaps read?
Powered by blists - more mailing lists