• Pavel Begunkov's avatar
    io_uring: optimise SQPOLL mm/files grabbing · 4e326358
    Pavel Begunkov authored
    There are two reasons for this. First is to optimise
    io_sq_thread_acquire_mm_files() for non-SQPOLL case, which currently do
    too many checks and function calls in the hot path, e.g. in
    io_init_req().
    
    The second is to not grab mm/files when there are not needed. As
    __io_queue_sqe() issues only one request now, we can reuse
    io_sq_thread_acquire_mm_files() instead of unconditional acquire
    mm/files.
    Signed-off-by: default avatarPavel Begunkov <asml.silence@gmail.com>
    Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
    4e326358
io_uring.c 247 KB