Questions tagged [io-uring]
37 questions
1
vote
1 answer
Does IOCP and io_uring read/write Asynchronous?
As far as I konw. Linux epoll is asynchronous notification. when a file descriptor become readable/writeable/acceptable, epoll_wait will return this fd. But read or write is still synchronous, will block thread.
So Redis 6.0 use a thread pool to…

LGG
- 31
- 1
- 3
1
vote
1 answer
why io_uring's submission queue indexing is different from completion queue?
From https://kernel.dk/io_uring.pdf, I noticed submission queue of io_uring requires another indirection of indexing. And the explaination is quite blurry for me.
One important difference is that while the CQ ring is directly indexing the shared…

slow_mohammud
- 77
- 7
1
vote
2 answers
Max registered buffers size in io_uring
I've tried to register a set of buffers by io_uring_register_buffers() but I couldn't register buffers big enough. Either one buffer bigger than 32768 bytes or a few buffers with the total size bigger 32768 lead to the ENOMEM error. I've read the…

Alexandr Ivanov
- 54
- 4
1
vote
1 answer
io_uring user_data field is always zero
I'm playing around with io_uring, https://kernel.dk/io_uring.pdf, to see if it can be used for async file I/O for logging. This is a simple program that opens a file, stats the file, and then reads the first 4k from the file. This program runs to…

Sean McCauliff
- 1,494
- 1
- 13
- 26
1
vote
1 answer
How much locked memory does io_uring_setup need?
When using io_uring_queue_init it calls io_uring_setup. There's an ENOMEM returned when there is insufficient amount of locked memory available for the process.
A strace will look something like:
[pid 37480] io_uring_setup(2048, {flags=0,…

danblack
- 12,130
- 2
- 22
- 41
1
vote
1 answer
How io-uring implementation is different from AIO?
Apparently, Linux already had an Asyn-IO (AIO) API. I believe it is not fully asynchronous. So what was the issue with AIO? and how io_uring overcomes it?
PS: I tried to read https://kernel.dk/io_uring.pdf but couldn't fully understand as I am out…

Govinda Sakhare
- 5,009
- 6
- 33
- 74
0
votes
1 answer
Is epoll a better API than io_uring?
With io_uring you have to submit a new read request whenever the previous read request has completed. This is unnatural in a lot of cases because you usually just want to keep reading from a TCP connection. With epoll you just register a file-handle…

levzettelin
- 2,600
- 19
- 32
0
votes
0 answers
If I use io_uring, kernel page cache management invlove in user buffer?
My application has a user buffer, and I want to manage my buffer directly with Linux io_uring.
According to the io_uring documentation, it explains that the user buffer is registered to the kernel. Therefore, It feel like the pages in my user buffer…

Dusol
- 47
- 8
0
votes
1 answer
io_uring: What is the use case for flag IORING_REGISTER_FILES_SKIP
In liburing library, after initial registration of file descriptors using io_uring_register_files api, we could use io_uring_register_files_update to update the file descriptors. The file descriptor can be set to special value…

AjaiS
- 1
- 1
0
votes
0 answers
Using syscalls from wasm in node.js?
I have some io_uring Rust code that I would like to use as a WASM module, but it needs to use syscalls to setup the ring and interface with it.
What's the easiest way to use syscalls from wasm in node.js?
Should I patch node or is there an easier…

Mascarpone
- 2,516
- 4
- 25
- 46
0
votes
1 answer
zeromq and liburing (io_uring)
can anybody tell what is the main difference between zeromq and liburing in case of building tcp server in C?
both can handle async requests and work with sockets. zeromq is older than liburing.

Manifestor
- 575
- 5
- 19
0
votes
0 answers
Am I misunderstanding how often IORING POLL is used?
I am watching a video that says after a million operations its faster to use io_uring_poll. I haven't used io_uring much so I may be remembering things wrong but io_uring poll means use io_uring_enter with the IORING_SETUP_SQPOLL flag? I understand…

Andrew Benor
- 51
- 6
0
votes
1 answer
What is the essential difference between event library (libevent/libuv/...) and async I/O (libaio, liburing)?
For high-performance I/O, some techniques are often used:
poll/select/epoll/kqueue: They are the same type of system calls that support I/O multiplexing.
libevent/libev/libuv: They are cross-platform. I think they wrap the above system calls and…

PDZ
- 1
0
votes
1 answer
How does io_uring handle short recvs when more data arrives on the socket?
Trying to find to retrieve data from io_uring efficiently. Short recv/send and the fragile SQE links have me blasting requests at the kernel to with most being cancelled.
If I request a recv of 8MB (basically the size of my user space buffer) and a…

JasonN
- 1,339
- 1
- 15
- 27
0
votes
1 answer
io_uring: io_uring_wait_cqe_nr, io_uring_peek_batch_cqe
I want to experiment io_uring on the github project:
https://github.com/alexhultman/io_uring_epoll_benchmark
referrence: https://unixism.net/loti/ref-liburing/completion.html
however I stumbled upon 2 functions:
unsigned…

QuickQuail
- 11
- 2