From: Chaitanya Kulkarni <chaitanyak@nvidia.com>
To: Uros Bizjak <ubizjak@gmail.com>,
"linux-nvme@lists.infradead.org" <linux-nvme@lists.infradead.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Cc: Christoph Hellwig <hch@lst.de>, Sagi Grimberg <sagi@grimberg.me>,
Chaitanya Kulkarni <chaitanyak@nvidia.com>
Subject: Re: [PATCH] nvmet: use try_cmpxchg in nvmet_update_sq_head
Date: Tue, 25 Oct 2022 00:47:05 +0000 [thread overview]
Message-ID: <220dabe6-dac1-8ca7-0134-e6e89c923d81@nvidia.com> (raw)
In-Reply-To: <20221020153540.8226-1-ubizjak@gmail.com>
On 10/20/22 08:35, Uros Bizjak wrote:
> Use try_cmpxchg instead of cmpxchg (*ptr, old, new) == old in
> nvmet_update_sq_head. x86 CMPXCHG instruction returns success in ZF flag, so
> this change saves a compare after cmpxchg (and related move instruction in
> front of cmpxchg).
>
Is it worth a share delts of assembly instructions of the changes above?
as developers on block mailing list are sharing the delta between before
and after patch including the assembly.
I also hope that you have tested this change with blktests nvme.
Either way:-
Reviewed-by: ChaItanya Kulkarni <kch@nvidia.com>
-ck
next prev parent reply other threads:[~2022-10-25 0:47 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-20 15:35 [PATCH] nvmet: use try_cmpxchg in nvmet_update_sq_head Uros Bizjak
2022-10-23 8:22 ` Sagi Grimberg
2022-10-25 0:47 ` Chaitanya Kulkarni [this message]
2022-10-25 6:48 ` Uros Bizjak
2022-11-01 9:45 ` Christoph Hellwig
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=220dabe6-dac1-8ca7-0134-e6e89c923d81@nvidia.com \
--to=chaitanyak@nvidia.com \
--cc=hch@lst.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-nvme@lists.infradead.org \
--cc=sagi@grimberg.me \
--cc=ubizjak@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