All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vlastimil Babka <vbabka@suse.cz>
To: "Lameter, Christopher" <cl@os.amperecomputing.com>,
	Michal Hocko <mhocko@suse.com>
Cc: "Huang, Ying" <ying.huang@intel.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-mm@kvack.org, linux-kernel@vger.kernel.org,
	Mel Gorman <mgorman@techsingularity.net>
Subject: Re: [PATCH] mm: fix draining remote pageset
Date: Tue, 5 Sep 2023 18:52:29 +0200	[thread overview]
Message-ID: <703e284d-186a-5699-f06c-761e51115ae0@suse.cz> (raw)
In-Reply-To: <94b0e0c6-a626-46a1-e746-a336d20cdc08@os.amperecomputing.com>

On 8/25/23 19:06, Lameter, Christopher wrote:
> On Tue, 22 Aug 2023, Michal Hocko wrote:
> 
>> Yes, this doesn't really show any actual correctness problem so I do not
>> think this is sufficient to change the code. You would need to show that
>> the existing behavior is actively harmful.
> 
> Having some pages from a remote NUMA node stuck in a pcp somewhere is 
> making that memory unusable. It is usually rate that these remote pages 
> are needed again and so they may remain there for a long time if the 
> situation is right.
> 
> And he is right that the intended behavior of freeing the remote pages 
> has been disabled by the patch.
> 
> So I think there is sufficient rationale to apply these fixes.

I wonder if this the optimum way to handle the NOHZ case? IIUC there we use
quiet_vmstat() to call refresh_cpu_vm_stats(). I'd expect if there were
pending remote pages to flush, it would be best to do it immediately, and
not keep a worker being requeued and only do that after the pcp->expires
goes zero.

However quiet_vmstat() even calls the refresh with do_pagesets == false. Why
do we even refresh the stats at that moment if the delayed update is pending
anyway? And could we maybe make sure that in that case the flush is done on
the first delayed update in that case and not expiring like this?

  parent reply	other threads:[~2023-09-05 18:09 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-11  9:08 [PATCH] mm: fix draining remote pageset Huang Ying
2023-08-11  9:35 ` Michal Hocko
2023-08-14  1:59   ` Huang, Ying
2023-08-16  6:49     ` Michal Hocko
2023-08-16  7:08       ` Huang, Ying
2023-08-16 20:23         ` Lameter, Christopher
2023-08-21  7:55         ` Michal Hocko
2023-08-21  8:30           ` Huang, Ying
2023-08-21  9:27             ` Michal Hocko
2023-08-21 22:31               ` Huang, Ying
2023-08-22  8:09                 ` Michal Hocko
2023-08-25 17:06                   ` Lameter, Christopher
2023-08-29  6:08                     ` Huang, Ying
2023-08-29 18:05                       ` Lameter, Christopher
2023-09-05 16:52                     ` Vlastimil Babka [this message]
2023-09-06  4:17                       ` Huang, Ying

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=703e284d-186a-5699-f06c-761e51115ae0@suse.cz \
    --to=vbabka@suse.cz \
    --cc=akpm@linux-foundation.org \
    --cc=cl@os.amperecomputing.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mgorman@techsingularity.net \
    --cc=mhocko@suse.com \
    --cc=ying.huang@intel.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.