The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Bart Van Assche <bvanassche@acm.org>
To: Yu Kuai <yukuai1@huaweicloud.com>,
	axboe@kernel.dk, ming.lei@redhat.com, nilay@linux.ibm.com,
	jmoyer@redhat.com
Cc: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org,
	yukuai3@huawei.com, yi.zhang@huawei.com, yangerkun@huawei.com,
	johnny.chenyi@huawei.com
Subject: Re: [patch v2 5/7] mq-deadline: covert to use request_queue->async_depth
Date: Thu, 9 Oct 2025 10:12:42 -0700	[thread overview]
Message-ID: <37a9cfa0-b6dd-4191-be41-ffa7b509b1a1@acm.org> (raw)
In-Reply-To: <20251009074634.527661-6-yukuai1@huaweicloud.com>

On 10/9/25 12:46 AM, Yu Kuai wrote:
> In downstream kernel, we test with mq-deadline with many fio workloads, and
> we found a performance regression after commit 39823b47bbd4
> ("block/mq-deadline: Fix the tag reservation code") with following test:
> 
> [global]
> rw=randread
> direct=1
> ramp_time=1
> ioengine=libaio
> iodepth=1024
> numjobs=24
> bs=1024k
> group_reporting=1
> runtime=60
> 
> [job1]
> filename=/dev/sda
> 
> Root cause is that mq-deadline now support configuring async_depth,
> although the default value is nr_request, however the minimal value is
> 1, hence min_shallow_depth is set to 1, causing wake_batch to be 1. For
> consequence, sbitmap_queue will be waken up after each IO instead of
> 8 IO.
> 
> In this test case, sda is HDD and max_sectors is 128k, hence each
> submitted 1M io will be splited into 8 sequential 128k requests, however
> due to there are 24 jobs and total tags are exhausted, the 8 requests are
> unlikely to be dispatched sequentially, and changing wake_batch to 1
> will make this much worse, accounting blktrace D stage, the percentage
> of sequential io is decreased from 8% to 0.8%.
> 
> Fix this problem by converting to request_queue->async_depth, where
> min_shallow_depth is set each time async_depth is updated.
> 
> Noted elevator attribute async_depth is now removed, queue attribute
> with the same name is used instead.

Reviewed-by: Bart Van Assche <bvanassche@acm.org>


  parent reply	other threads:[~2025-10-09 17:13 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-09  7:46 [patch v2 0/7] blk-mq: introduce new queue attribute async_depth Yu Kuai
2025-10-09  7:46 ` [patch v2 1/7] block: convert nr_requests to unsigned int Yu Kuai
2025-10-09  7:46 ` [patch v2 2/7] blk-mq-sched: unify elevators checking for async requests Yu Kuai
2025-10-09 11:15   ` Nilay Shroff
2025-10-09 17:02   ` Bart Van Assche
2025-10-10  2:01     ` Yu Kuai
2025-10-09  7:46 ` [patch v2 3/7] blk-mq: add a new queue sysfs attribute async_depth Yu Kuai
2025-10-09 11:20   ` Nilay Shroff
2025-10-09 17:05   ` Bart Van Assche
2025-10-09 17:19     ` Yu Kuai
2025-10-09  7:46 ` [patch v2 4/7] kyber: covert to use request_queue->async_depth Yu Kuai
2025-10-09 11:20   ` Nilay Shroff
2025-10-09  7:46 ` [patch v2 5/7] mq-deadline: " Yu Kuai
2025-10-09 11:21   ` Nilay Shroff
2025-10-09 17:12   ` Bart Van Assche [this message]
2025-10-09  7:46 ` [patch v2 6/7] block, bfq: convert " Yu Kuai
2025-10-09 11:22   ` Nilay Shroff
2025-10-09  7:46 ` [patch v2 7/7] blk-mq: add documentation for new queue attribute async_dpeth Yu Kuai
2025-10-09 11:22   ` Nilay Shroff

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=37a9cfa0-b6dd-4191-be41-ffa7b509b1a1@acm.org \
    --to=bvanassche@acm.org \
    --cc=axboe@kernel.dk \
    --cc=jmoyer@redhat.com \
    --cc=johnny.chenyi@huawei.com \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ming.lei@redhat.com \
    --cc=nilay@linux.ibm.com \
    --cc=yangerkun@huawei.com \
    --cc=yi.zhang@huawei.com \
    --cc=yukuai1@huaweicloud.com \
    --cc=yukuai3@huawei.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