]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: optimize submit_and_wait API
authorJens Axboe <axboe@kernel.dk>
Mon, 9 Sep 2019 22:19:45 +0000 (16:19 -0600)
committerJens Axboe <axboe@kernel.dk>
Tue, 10 Sep 2019 14:21:03 +0000 (08:21 -0600)
commit262c087954bb9749ae49ff0017ffbce5065e9261
treec32decec36832a25c82d8430ef80bd3c2375d437
parent11e836fc4d95d243ed84e6dabd473d631e32061f
io_uring: optimize submit_and_wait API

For some applications that end up using a submit-and-wait type of
approach for certain batches of IO, we can make that a bit more
efficient by allowing the application to block for the last IO
submission. This prevents an async when we don't need it, as the
application will be blocking for the completion event(s) anyway.

Typical use cases are using the liburing
io_uring_submit_and_wait() API, or just using io_uring_enter()
doing both submissions and completions. As a specific example,
RocksDB doing MultiGet() is sped up quite a bit with this
change.

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