io_uring: remove next io_kiocb fetch in task_work running
authorJens Axboe <axboe@kernel.dk>
Wed, 31 Jan 2024 17:39:05 +0000 (10:39 -0700)
committerJens Axboe <axboe@kernel.dk>
Thu, 8 Feb 2024 20:27:06 +0000 (13:27 -0700)
We just reversed the task_work list and that will have touched requests
as well, just get rid of this optimization as it should not make a
difference anymore.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
io_uring/io_uring.c

index 4678d9ec810be7496054d7272a4b50c120e714d4..007cef9738eeeab97703a821ea3d5f7b98708ebe 100644 (file)
@@ -1184,8 +1184,6 @@ static unsigned int handle_tw_list(struct llist_node *node,
                struct io_kiocb *req = container_of(node, struct io_kiocb,
                                                    io_task_work.node);
 
-               prefetch(container_of(next, struct io_kiocb, io_task_work.node));
-
                if (req->ctx != *ctx) {
                        ctx_flush_and_put(*ctx, ts);
                        *ctx = req->ctx;
@@ -1408,7 +1406,6 @@ again:
                struct llist_node *next = node->next;
                struct io_kiocb *req = container_of(node, struct io_kiocb,
                                                    io_task_work.node);
-               prefetch(container_of(next, struct io_kiocb, io_task_work.node));
                INDIRECT_CALL_2(req->io_task_work.func,
                                io_poll_task_func, io_req_rw_complete,
                                req, ts);