All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCHSET RFC 0/4] Add support for IOSQE2_POLL_FIRST
@ 2022-04-26 18:33 Jens Axboe
  2022-04-26 18:33 ` [PATCH 1/4] io_uring: check IOPOLL/ioprio support upfront Jens Axboe
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Jens Axboe @ 2022-04-26 18:33 UTC (permalink / raw)
  To: io-uring

Hi,

For some workloads, it's not at all uncommon that every request will end
up using the internal poll feature to trigger the successful execution of
a request. This is quite common for network receive, where the application
doesn't expect any data to be immediately available. Yet we still attempt
to do this receive, then get -EAGAIN, arm poll, and trigger the retry
based on poll.

This can be quite wasteful, and particularly so for cases where we
expect to arm poll basically 100% of the time.

This series builds to adding support for asking io_uring to arm poll
first, rather than first attempt an IO, and finally adds support for
this feature to send/sendmsg and recv/recvmsg (with the two latter ones
being the most useful, imho).

Given that most requests don't support IO priorities, a new flags2 field
is added using that same space. The last bit we have in sqe->flags is
added to say that "ioprio is really flags2". This does mean that any
IOSQE2_ flags added cannot be used with IO priorities.

-- 
Jens Axboe



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

end of thread, other threads:[~2022-04-26 18:33 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-26 18:33 [PATCHSET RFC 0/4] Add support for IOSQE2_POLL_FIRST Jens Axboe
2022-04-26 18:33 ` [PATCH 1/4] io_uring: check IOPOLL/ioprio support upfront Jens Axboe
2022-04-26 18:33 ` [PATCH 2/4] io_uring: add flags2 variable Jens Axboe
2022-04-26 18:33 ` [PATCH 3/4] io_uring: add IOSQE2_POLL_FIRST flag Jens Axboe
2022-04-26 18:33 ` [PATCH 4/4] io_uring: wire up IOSQE2_POLL_FIRST for send/sendmsg and recv/recvmsg Jens Axboe

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.