From: Tejun Heo <tj@kernel.org>
To: chengming.zhou@linux.dev
Cc: josef@toxicpanda.com, axboe@kernel.dk, cgroups@vger.kernel.org,
linux-block@vger.kernel.org, linux-kernel@vger.kernel.org,
zhouchengming@bytedance.com
Subject: Re: [PATCH] blk-iocost: skip empty flush bio in iocost
Date: Thu, 20 Jul 2023 09:59:37 -1000 [thread overview]
Message-ID: <ZLmSKdW5wTx0dAlz@slm.duckdns.org> (raw)
In-Reply-To: <20230720121441.1408522-1-chengming.zhou@linux.dev>
On Thu, Jul 20, 2023 at 08:14:41PM +0800, chengming.zhou@linux.dev wrote:
> From: Chengming Zhou <zhouchengming@bytedance.com>
>
> The flush bio may have data, may have no data (empty flush), we couldn't
> calculate cost for empty flush bio. So we'd better just skip it for now.
>
> Another side effect is that empty flush bio's bio_end_sector() is 0, cause
> iocg->cursor reset to 0, may break the cost calculation of other bios.
>
> This isn't good enough, since flush bio still consume the device bandwidth,
> but flush request is special, can be merged randomly in the flush state
> machine, we don't know how to calculate cost for it for now.
>
> Its completion time also has flaws, which may include the pre-flush or
> post-flush completion time, but I don't know if we need to fix that and
> how to fix it.
>
> Signed-off-by: Chengming Zhou <zhouchengming@bytedance.com>
It's unlikely that this will change behaviors in an observable way in most
cases. That said, yeah, ignoring it in terms of cost calculation is likely
the better thing to do.
Acked-by: Tejun Heo <tj@kernel.org>
Thanks.
--
tejun
next prev parent reply other threads:[~2023-07-20 19:59 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-20 12:14 chengming.zhou
2023-07-20 19:59 ` Tejun Heo [this message]
2023-07-20 20:02 ` Jens Axboe
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=ZLmSKdW5wTx0dAlz@slm.duckdns.org \
--to=tj@kernel.org \
--cc=axboe@kernel.dk \
--cc=cgroups@vger.kernel.org \
--cc=chengming.zhou@linux.dev \
--cc=josef@toxicpanda.com \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=zhouchengming@bytedance.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®