mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Joel Fernandes <joelagnelf@nvidia.com>
To: paulmck@kernel.org
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Frederic Weisbecker <frederic@kernel.org>,
	Neeraj Upadhyay <neeraj.upadhyay@kernel.org>,
	Joel Fernandes <joel@joelfernandes.org>,
	Josh Triplett <josh@joshtriplett.org>,
	Boqun Feng <boqun.feng@gmail.com>,
	Uladzislau Rezki <urezki@gmail.com>,
	Steven Rostedt <rostedt@goodmis.org>,
	Mathieu Desnoyers <mathieu.desnoyers@efficios.com>,
	Lai Jiangshan <jiangshanlai@gmail.com>,
	Zqiang <qiang.zhang1211@gmail.com>,
	"rcu@vger.kernel.org" <rcu@vger.kernel.org>
Subject: Re: [PATCH 1/3] rcu: Replace magic number with meaningful constant in rcu_seq_done_exact()
Date: Thu, 27 Mar 2025 22:31:41 -0400	[thread overview]
Message-ID: <919f17a3-2199-4c97-a1f8-5434098eb509@nvidia.com> (raw)
In-Reply-To: <e47e5611-36de-4d12-9c07-57aa2a885299@paulmck-laptop>



On 3/27/2025 1:09 PM, Paul E. McKenney wrote:
>>> In contrast, making the guard band a bit longer than it needs to be
>>> has little or no downside.
>> Making it 3 GP instead of 2 should be ok with me as long as we document it but at least it will not be a magic number based on an equation. I feel we should not put random magic numbers which is more dangerous since it is hard to explain (and hence debug — just my 2 cents).
> Apologies, I was getting ahead of us on this one.
> 
> That third (and maybe also a fourth) grace period becomes important if
> we start getting memory contention on rcu_state.gp_seq, in which case
> we would want the polled grace periods to look at the leaf rcu_node
> structure's gp_seq, which would introduce extra slop.

Makes sense.

> For now, for this patch, assuming you guys promise to remember this
> should such memory contention prove problematic:
> 
> Reviewed-by: Paul E. McKenney <paulmck@kernel.org>

Thanks! Will add the tag.

 - Joel


  reply	other threads:[~2025-03-28  2:31 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-24 17:01 [PATCH 0/3] rcu_seq_done_exact() improvements Joel Fernandes
2025-03-24 17:01 ` [PATCH 1/3] rcu: Replace magic number with meaningful constant in rcu_seq_done_exact() Joel Fernandes
2025-03-26 22:33   ` Paul E. McKenney
2025-03-26 22:42     ` Joel Fernandes
2025-03-27 17:09       ` Paul E. McKenney
2025-03-28  2:31         ` Joel Fernandes [this message]
2025-03-30 22:10         ` Frederic Weisbecker
2025-03-31 18:28           ` Paul E. McKenney
2025-03-31 21:14             ` Frederic Weisbecker
2025-03-31 21:29               ` Paul E. McKenney
2025-04-01 13:38                 ` Frederic Weisbecker
2025-04-02  4:24                   ` Paul E. McKenney
2025-03-24 17:01 ` [PATCH 2/3] rcu: Add warning to ensure rcu_seq_done_exact() is working Joel Fernandes
2025-03-26 22:36   ` Paul E. McKenney
2025-03-26 22:50     ` Joel Fernandes
2025-03-26 23:21       ` Paul E. McKenney
2025-03-24 17:01 ` [PATCH 3/3] rcu: Comment on the extraneous delta test on rcu_seq_done_exact() Joel Fernandes
2025-03-26 22:37   ` Paul E. McKenney
2025-03-26 22:51     ` Joel Fernandes

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=919f17a3-2199-4c97-a1f8-5434098eb509@nvidia.com \
    --to=joelagnelf@nvidia.com \
    --cc=boqun.feng@gmail.com \
    --cc=frederic@kernel.org \
    --cc=jiangshanlai@gmail.com \
    --cc=joel@joelfernandes.org \
    --cc=josh@joshtriplett.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mathieu.desnoyers@efficios.com \
    --cc=neeraj.upadhyay@kernel.org \
    --cc=paulmck@kernel.org \
    --cc=qiang.zhang1211@gmail.com \
    --cc=rcu@vger.kernel.org \
    --cc=rostedt@goodmis.org \
    --cc=urezki@gmail.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 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®