It'd be kinda awesome if we could have an io_uring with multiple submission queues/rings, but only one completion queue/ring. With the ability to map the submission queue only in one process, but the completion queue in multiple.
CC: @axboe
-
Show this thread
-
Replying to @AndresFreundTec
Agree, it would be pretty nifty! Would not be hard to do, I think the hardest part would actually be the liburing side of it.
1 reply 0 retweets 2 likes -
Replying to @axboe
If it'd require more manual work to set up, it'd be fair enough. Though it turns out that the contention I was just seeing was unnecessary. Still bothersome to have to be careful to hold submission side lock until all submissions have to be consumed by kernel (due to mm/fds).
1 reply 0 retweets 0 likes -
Replying to @AndresFreundTec
It'd be trivial to ensure things are correct and eliminate any need to think about locking, which is always a win on the application side imho. I'll have to think about it a bit.
2 replies 0 retweets 1 like -
Replying to @axboe
Cool! Random update: FWIW, got PG to be competitive with io_uring based AIO for several workloads (but file appending is really bad right now). But only when using DIO, buffered has considerably higher CPU usage/contention.
2 replies 0 retweets 1 like -
Replying to @AndresFreundTec @axboe
The slowdown for buffered IO is noticeable both when the data is in the page cache (because submission lock is held while copying all the data), and when not (the number of io-wq workers causing CPU overhead, partially due to contention).
1 reply 0 retweets 0 likes -
Replying to @AndresFreundTec
For the read side, it should be no slower than read(2) eg if cached, but if you need locking held over the copy, then that's definitely a concern. For read side buffered IO, my goal is to make this work through page waitqueue callbacks and eliminate the need for io-wq.
2 replies 0 retweets 0 likes
And yea, the locks that need to be held through the submission are problematic. Partially can be addressed w IOSQE_ASYNC, with the obvious trade-offs.
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.