All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] workqueue: Shrink the lock time
@ 2026-05-26 18:08 Breno Leitao
  2026-05-26 18:08 ` [PATCH 1/2] workqueue: split kick_pool() into kick_pool_pick() + wake_up_process() Breno Leitao
  2026-05-26 18:08 ` [PATCH 2/2] workqueue: defer wake_up_process() outside pool->lock on hot paths Breno Leitao
  0 siblings, 2 replies; 11+ messages in thread
From: Breno Leitao @ 2026-05-26 18:08 UTC (permalink / raw)
  To: Tejun Heo, Lai Jiangshan
  Cc: linux-kernel, marco.crivellari, frederic, bigeasy, Breno Leitao,
	kernel-team

The goal of this patchset is to decrease the time spent on the
workqueue pool->lock.

Currently, the worker process is woken up inside the lock, which can
be expensive on some architectures.  On arm64, the wake-up issues an
IPI when the target CPU is in idle (wfi on arm64), which requires an
interrupt to wake it. And also, the rq lock, which will be nested in
this case.

This series decreases the time spent under pool->lock by waking up
the process outside of the lock. This improves the microbenchark we have
in lib/ by up to 10%.

Signed-off-by: Breno Leitao <leitao@debian.org>
---
Breno Leitao (2):
      workqueue: split kick_pool() into kick_pool_pick() + wake_up_process()
      workqueue: defer wake_up_process() outside pool->lock on hot paths

 kernel/workqueue.c | 57 ++++++++++++++++++++++++++++++++++++++++++++++--------
 1 file changed, 49 insertions(+), 8 deletions(-)
---
base-commit: c1ecb239fa3456529a32255359fc78b69eb9d847
change-id: 20260526-fastwake-02982fd66312

Best regards,
--  
Breno Leitao <leitao@debian.org>


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2026-06-01 17:27 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-26 18:08 [PATCH 0/2] workqueue: Shrink the lock time Breno Leitao
2026-05-26 18:08 ` [PATCH 1/2] workqueue: split kick_pool() into kick_pool_pick() + wake_up_process() Breno Leitao
2026-05-26 18:08 ` [PATCH 2/2] workqueue: defer wake_up_process() outside pool->lock on hot paths Breno Leitao
2026-05-26 21:23   ` Hillf Danton
2026-05-27  9:48     ` Breno Leitao
2026-05-27 14:51       ` Breno Leitao
2026-05-27 15:35         ` Sebastian Andrzej Siewior
2026-05-28 14:35           ` Breno Leitao
2026-06-01 17:26           ` Breno Leitao
2026-05-27 15:22   ` Sebastian Andrzej Siewior
2026-05-28 13:41     ` Breno Leitao

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.