eventcore icon indicating copy to clipboard operation
eventcore copied to clipboard

Use io_uring where sensible

Open Panke opened this issue 3 years ago • 1 comments

I am investigating the usage of io_uring as a backend for eventcore. Let's gather all discussion surrounding it in this issue.

To the best of my understanding there are two approaches to do this.

  1. Integrate it into the posix event loop as an additional event source similar to timers. Wake up the posix event loop by registering an eventfd that fires, when io_uring completions are available. This is done in the outstanding PR.
  2. Replace the posix event loop with an io_uring based event loop completely. Since io_uring does not support everything at the moment (notably signalfd does not work), we have to support epoll as well via IO_URING_OP_POLL_ADD.

Panke avatar Mar 26 '21 11:03 Panke

This seems to lend itself nicely for starting with 1, switching to 2 once a certain level of completeness is reached (IMO, at least sockets + files + events + pipes). Timers would probably go together with the switch, but could also stay implemented with the current approach of limiting the wait operation according to the earliest timer.

s-ludwig avatar Mar 26 '21 15:03 s-ludwig