mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Hillf Danton <hdanton@sina.com>
To: Frederic Weisbecker <frederic@kernel.org>
Cc: LKML <linux-kernel@vger.kernel.org>,
	Oleg Nesterov <oleg@redhat.com>, Michal Hocko <mhocko@kernel.org>,
	linux-mm@kvack.org, Marcelo Tosatti <mtosatti@redhat.com>,
	Vlastimil Babka <vbabka@suse.cz>,
	Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [PATCH 0/6 v3] sched/mm: LRU drain flush on nohz_full
Date: Wed,  2 Jul 2025 19:54:52 +0800	[thread overview]
Message-ID: <20250702115454.2183-1-hdanton@sina.com> (raw)
In-Reply-To: <aGPWYWKKWhr2rxMG@localhost.localdomain>

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=UTF-8, Size: 2857 bytes --]

On Tue, 1 Jul 2025 14:36:49 +0200 Frederic Weisbecker wrote
>Le Sat, Apr 12, 2025 at 10:58:22AM +0800, Hillf Danton a écrit :
>> On Thu, 10 Apr 2025 17:23:21 +0200 Frederic Weisbecker wrote
>> > Hi,
>> > 
>> > When LRUs are pending, the drain can be triggered remotely, whether the
>> > remote CPU is running in userspace in nohz_full mode or not. This kind
>> > of noise is expected to be caused by preparatory work before a task
>> > runs isolated in userspace. This patchset is a proposal to flush that
>> > before the task starts its critical work in userspace.
>> > 
>> Alternatively add a syscall for workloads on isolated CPUs to flush
>> this xxx and prepare that yyy before entering the critical work, instead
>> of adding random (nice) patches today and next month. Even prctl can
>> do lru_add_and_bh_lrus_drain(), and prctl looks more preferable over
>> adding a syscall.
>
>In an ideal world, this is indeed what we should do now. And I still wish we
>can do this in the future.
>
>The problem is that this has been tried by the past and the work was never
>finished because that syscall eventually didn't meet the need for the people
>working on it.
>
>I would volunteer to start a simple prctl to do such a flush, something that
>can be extended in the future, should the need arise, but such a new ABI must
>be thought through along with the CPU isolation community.
>
>Unfortunately there is no such stable CPU isolation community. Many developers
>in this area contribute changes and then switch to other things. As for the CPU
>isolation users, they are usually very quiet.
>
Given your footprint in the MAINTAINERS file,

HIGH-RESOLUTION TIMERS, TIMER WHEEL, CLOCKEVENTS
M:	Anna-Maria Behnsen <anna-maria@linutronix.de>
M:	Frederic Weisbecker <frederic@kernel.org>
M:	Thomas Gleixner <tglx@linutronix.de>

NOHZ, DYNTICKS SUPPORT
M:	Anna-Maria Behnsen <anna-maria@linutronix.de>
M:	Frederic Weisbecker <frederic@kernel.org>
M:	Ingo Molnar <mingo@kernel.org>
M:	Thomas Gleixner <tglx@linutronix.de>

POSIX CLOCKS and TIMERS
M:	Anna-Maria Behnsen <anna-maria@linutronix.de>
M:	Frederic Weisbecker <frederic@kernel.org>
M:	Thomas Gleixner <tglx@linutronix.de>

READ-COPY UPDATE (RCU)
M:	"Paul E. McKenney" <paulmck@kernel.org>
M:	Frederic Weisbecker <frederic@kernel.org> (kernel/rcu/tree_nocb.h)
M:	Neeraj Upadhyay <neeraj.upadhyay@kernel.org> (kernel/rcu/tasks.h)
M:	Joel Fernandes <joel@joelfernandes.org>
M:	Josh Triplett <josh@joshtriplett.org>
M:	Boqun Feng <boqun.feng@gmail.com>
M:	Uladzislau Rezki <urezki@gmail.com>

I am happy to close the chance for you to deliver patch like a starter.

>I can't assume all the possible usecases myself and therefore I would easily do
>it wrong.
>
>In the meantime, the patchset here is a proposal that hopefully should work for
>many usecases.
>
>Thanks.
>
>-- 
>Frederic Weisbecker
>SUSE Labs

      reply	other threads:[~2025-07-02 11:55 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-10 15:23 Frederic Weisbecker
2025-04-10 15:23 ` [PATCH 1/6] task_work: Provide means to check if a work is queued Frederic Weisbecker
2025-04-10 15:23 ` [PATCH 2/6] sched/fair: Use task_work_queued() on numa_work Frederic Weisbecker
2025-04-10 15:23 ` [PATCH 3/6] sched: Use task_work_queued() on cid_work Frederic Weisbecker
2025-04-10 15:23 ` [PATCH 4/6] tick/nohz: Move nohz_full related fields out of hot task struct's places Frederic Weisbecker
2025-04-23 18:40   ` Shrikanth Hegde
2025-07-01 12:17     ` Frederic Weisbecker
2025-04-10 15:23 ` [PATCH 5/6] sched/isolation: Introduce isolated task work Frederic Weisbecker
2025-04-11 10:25   ` Oleg Nesterov
2025-04-11 22:00     ` Frederic Weisbecker
2025-04-12  5:12     ` K Prateek Nayak
2025-04-10 15:23 ` [PATCH 6/6] mm: Drain LRUs upon resume to userspace on nohz_full CPUs Frederic Weisbecker
     [not found] ` <20250412025831.4010-1-hdanton@sina.com>
2025-07-01 12:36   ` [PATCH 0/6 v3] sched/mm: LRU drain flush on nohz_full Frederic Weisbecker
2025-07-02 11:54     ` Hillf Danton [this message]

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=20250702115454.2183-1-hdanton@sina.com \
    --to=hdanton@sina.com \
    --cc=akpm@linux-foundation.org \
    --cc=frederic@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mhocko@kernel.org \
    --cc=mtosatti@redhat.com \
    --cc=oleg@redhat.com \
    --cc=vbabka@suse.cz \
    /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

all inboxes | Powered by JetHome®