mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Gabriele Monaco <gmonaco@redhat.com>
To: Thomas Gleixner <tglx@linutronix.de>,
	Mathieu Desnoyers <mathieu.desnoyers@efficios.com>,
	Ingo Molnar <mingo@redhat.com>,
	Peter Zijlstra <peterz@infradead.org>
Cc: linux-kernel@vger.kernel.org,
	Andrew Morton <akpm@linux-foundation.org>,
	David Hildenbrand	 <david@redhat.com>,
	linux-mm@kvack.org, "Paul E. McKenney" <paulmck@kernel.org>
Subject: Re: [PATCH v2 2/4] rseq: Run the mm_cid_compaction from rseq_handle_notify_resume()
Date: Tue, 30 Sep 2025 12:18:18 +0200	[thread overview]
Message-ID: <2bf22dc5213ada5339d85744c348da9558f25e3d.camel@redhat.com> (raw)
In-Reply-To: <87tt0k3oks.ffs@tglx>

On Tue, 2025-09-30 at 00:01 +0200, Thomas Gleixner wrote:
> 
> The current overhead of RSEQ is way too high. People have reported 3%
> regressions just because glibc uses RSEQ now. So that needs to be
> addressed. Moving the RSEQ fastpath to the last point before going back
> to user space is the correct thing to do.
> 
> mm cid compaction is a related but orthogonal problem. I just skimmed
> your patches and I'm really not convinced that this is the right
> approach to solve the problem.
> 
> The main issue with task_mm_cid_work() is that it iterates over all
> possible CPUs twice. Your batching just makes the impact smaller, but it
> does not really try to change the overall approach to this.

Thanks for the thorough explanation and sketch implementation. As I'm not really
confident with rseq I didn't dare changing the compaction logic too much, but
clearly your approach of getting compact cid by construction seems the way to
go.

I confirm your patch passes the selftest in 4/4 of this series and, obviously,
removes the latency I was observing.

Thanks,
Gabriele


  reply	other threads:[~2025-09-30 10:18 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-16 16:06 [PATCH v2 0/4] sched: Run task_mm_cid_work in batches to lower latency Gabriele Monaco
2025-07-16 16:06 ` [PATCH v2 1/4] sched: Add prev_sum_exec_runtime support for RT, DL and SCX classes Gabriele Monaco
2025-07-16 16:06 ` [PATCH v2 2/4] rseq: Run the mm_cid_compaction from rseq_handle_notify_resume() Gabriele Monaco
2025-08-26 18:01   ` Mathieu Desnoyers
2025-08-27  6:55     ` Gabriele Monaco
2025-09-24 15:22     ` Gabriele Monaco
2025-09-29 22:01       ` Thomas Gleixner
2025-09-30 10:18         ` Gabriele Monaco [this message]
2025-10-02  1:22         ` Thomas Gleixner
2025-07-16 16:06 ` [PATCH v2 3/4] sched: Compact RSEQ concurrency IDs in batches Gabriele Monaco
2025-08-05 12:42   ` Gabriele Monaco
2025-08-06 16:57     ` Mathieu Desnoyers
2025-08-06 18:24       ` Gabriele Monaco
2025-08-26 18:10   ` Mathieu Desnoyers
2025-08-28  8:36     ` Gabriele Monaco
2025-07-16 16:06 ` [PATCH v2 4/4] selftests/rseq: Add test for mm_cid compaction Gabriele Monaco

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=2bf22dc5213ada5339d85744c348da9558f25e3d.camel@redhat.com \
    --to=gmonaco@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=david@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mathieu.desnoyers@efficios.com \
    --cc=mingo@redhat.com \
    --cc=paulmck@kernel.org \
    --cc=peterz@infradead.org \
    --cc=tglx@linutronix.de \
    /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®