From: Jason Gunthorpe <jgg@nvidia.com>
To: Bob Pearson <rpearsonhpe@gmail.com>
Cc: zyjzyj2000@gmail.com, frank.zago@hpe.com, ian.ziemba@hpe.com,
jhack@hpe.com, linux-rdma@vger.kernel.org
Subject: Re: [PATCH for-next] RDMA/rxe: Fix potential race in rxe_pool_get_index
Date: Mon, 10 Jul 2023 15:15:21 -0300 [thread overview]
Message-ID: <ZKxKuaTRk9a2hM/+@nvidia.com> (raw)
In-Reply-To: <8a34d5b4-1bd9-c2e6-aca2-ab34f4ca1e2e@gmail.com>
On Mon, Jul 10, 2023 at 01:11:28PM -0500, Bob Pearson wrote:
> New news on this. After some testing it turns out that replacing
> rcu_read_lock() by xa_lock_irqsave() in rxe_pool_get_index() with a
> large number of QPs has very bad performance. ib_send_bw -q 32
> spends about 40% of its time trying to get the spinlock on a 24
> thread CPU with local loopback. With rcu_read_lock performance is
> what I expect. So, since we don't actually see this race we are
> reverting that change. Without it the irqsave locks aren't required
> either. So for now please ignore this patch.
Well, no, you need to fix this now that you found it - you need to
make the core code RCU free things that rxe thinks are rcu protected.
And maybe we should just have the core code do it always, we've wanted
RCU objects for other reasons anyhow.
Jason
prev parent reply other threads:[~2023-07-10 18:15 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-29 22:30 [PATCH for-next] RDMA/rxe: Fix potential race in rxe_pool_get_index Bob Pearson
2023-06-29 23:18 ` Jason Gunthorpe
2023-06-30 15:33 ` Bob Pearson
2023-07-10 16:47 ` Jason Gunthorpe
2023-07-10 18:11 ` Bob Pearson
2023-07-10 18:15 ` Jason Gunthorpe [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=ZKxKuaTRk9a2hM/+@nvidia.com \
--to=jgg@nvidia.com \
--cc=frank.zago@hpe.com \
--cc=ian.ziemba@hpe.com \
--cc=jhack@hpe.com \
--cc=linux-rdma@vger.kernel.org \
--cc=rpearsonhpe@gmail.com \
--cc=zyjzyj2000@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