mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Yao Kai <yaokai34@huawei.com>
To: Tejun Heo <tj@kernel.org>
Cc: Lai Jiangshan <jiangshanlai@gmail.com>,
	Breno Leitao <leitao@debian.org>, <linux-kernel@vger.kernel.org>,
	liuyongqiang <liuyongqiang13@huawei.com>
Subject: Re: [QUESTION] workqueue: Reducing flush_workqueue() overhead for unbound workqueues
Date: Mon, 7 Sep 2026 10:19:20 +0800	[thread overview]
Message-ID: <4b7d4054-633c-4958-9283-2d34f0a0e50f@huawei.com> (raw)
In-Reply-To: <92e520050991ea409925012255480655@kernel.org>



On 9/2/2026 5:11 AM, Tejun Heo wrote:
> Hello,
> 
> On Tue, Sep 01, 2026 at 04:46:06PM +0800, Yao Kai wrote:
>> Is there a recommended way to avoid this overhead for such case,
>> I would appreciate guidance on how this problem should be solved.
> 
> Posted a patchset which makes flush_workqueue() visit only the pwqs which
> have been active since the last flush:
> 
>    https://lore.kernel.org/all/20260901210929.3092513-1-tj@kernel.org/
> 
> Can you please test whether it resolves the fsync latency issue you're
> seeing?
> 
> Thanks.
> 
> --
> tejun

Sorry for the late reply. Because my server encountered a hardware failure,
I was unable to test the previous comparison data.

This issue was discovered when running MySQL sysbench on XFS. When we
migrated the kernel from 5.10 to 6.6, we observed a 60% performance drop
in MySQL sysbench. After investigation, we found that the time spent on
`flush_workqueue_prep_pwqs` had increased significantly.

After my colleague applied your new patches, the performance of MySQL
sysbench returned to the level of the 5.10 kernel, so I believe this
can solve the problem.

Thanks,
Yao

  reply	other threads:[~2026-09-07  2:19 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-01  8:46 Yao Kai
2026-09-01 21:11 ` Tejun Heo
2026-09-07  2:19   ` Yao Kai [this message]
2026-09-08 17:35     ` Tejun Heo

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=4b7d4054-633c-4958-9283-2d34f0a0e50f@huawei.com \
    --to=yaokai34@huawei.com \
    --cc=jiangshanlai@gmail.com \
    --cc=leitao@debian.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=liuyongqiang13@huawei.com \
    --cc=tj@kernel.org \
    /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®