Linux io-uring development
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@kernel.dk>
To: kernel test robot <oliver.sang@intel.com>,
	Gabriel Krisman Bertazi <krisman@suse.de>
Cc: oe-lkp@lists.linux.dev, lkp@intel.com, io-uring@vger.kernel.org
Subject: Re: [linux-next:master] [io_uring/rw] 8cf0c45999: fio.read_bw_MBps 51.1% regression
Date: Fri, 27 Dec 2024 09:48:58 -0700	[thread overview]
Message-ID: <98fc1d1e-2b39-4628-a209-a76407130f6c@kernel.dk> (raw)
In-Reply-To: <202412271132.a09c3500-lkp@intel.com>

On 12/26/24 8:13 PM, kernel test robot wrote:
> 
> 
> Hello,
> 
> kernel test robot noticed a 51.1% regression of fio.read_bw_MBps on:
> 
> 
> commit: 8cf0c459993ee2911f4f01fba21b1987b102c887 ("io_uring/rw: Allocate async data through helper")
> https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git master
> 
> [test failed on linux-next/master 8155b4ef3466f0e289e8fcc9e6e62f3f4dceeac2]

Took a quick look, and I think that patch forgets to clear ->bytes_done
when we don't have a free_iovec. That looks like a mistake, it should
always get cleared, it has no dependence on ->free_iovec.

diff --git a/io_uring/rw.c b/io_uring/rw.c
index 75f70935ccf4..ca1b19d3d142 100644
--- a/io_uring/rw.c
+++ b/io_uring/rw.c
@@ -228,8 +228,8 @@ static int io_rw_alloc_async(struct io_kiocb *req)
 		kasan_mempool_unpoison_object(rw->free_iovec,
 					      rw->free_iov_nr * sizeof(struct iovec));
 		req->flags |= REQ_F_NEED_CLEANUP;
-		rw->bytes_done = 0;
 	}
+	rw->bytes_done = 0;
 	return 0;
 }
 

-- 
Jens Axboe

  reply	other threads:[~2024-12-27 16:49 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-27  3:13 [linux-next:master] [io_uring/rw] 8cf0c45999: fio.read_bw_MBps 51.1% regression kernel test robot
2024-12-27 16:48 ` Jens Axboe [this message]
2024-12-31  6:36   ` Oliver Sang

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=98fc1d1e-2b39-4628-a209-a76407130f6c@kernel.dk \
    --to=axboe@kernel.dk \
    --cc=io-uring@vger.kernel.org \
    --cc=krisman@suse.de \
    --cc=lkp@intel.com \
    --cc=oe-lkp@lists.linux.dev \
    --cc=oliver.sang@intel.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