]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: batch task_work
authorDylan Yudaken <dylany@fb.com>
Wed, 22 Jun 2022 13:40:25 +0000 (06:40 -0700)
committerJens Axboe <axboe@kernel.dk>
Mon, 25 Jul 2022 00:39:15 +0000 (18:39 -0600)
commit764ecc815ea68e389c4819d61de58270bcb0e183
tree732709a212417c60ee42eabc36859d59538f2ac3
parent0dedfba9d0dae0e9be8e4dc6a7b0f712cfd6d9e6
io_uring: batch task_work

Batching task work up is an important performance optimisation, as
task_work_add is expensive.

In order to keep the semantics replace the task_list with a fake node
while processing the old list, and then do a cmpxchg at the end to see if
there is more work.

Signed-off-by: Dylan Yudaken <dylany@fb.com>
Link: https://lore.kernel.org/r/20220622134028.2013417-6-dylany@fb.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
io_uring/io_uring.c