News for hackers. Stuff that matters.
Re:How fast are Linux pipes anyway? by 0d0a on Friday October 06, 2023 @03:47AM (#37788171)
Can you give some examples? When batching data, you benefit from picking something like io_uring. But for two-way communication, you still need to notify either side when data is ready (maybe you don't want to consume cpu just polling), and it isn't clear to me how those options handle that synchronization faster than pipes.
Re:How fast are Linux pipes anyway? by _trackno5 on Friday October 06, 2023 @04:29AM (#37788354)
The main thing io_uring gives you is avoiding multiple syscalls.

With a pipe you can’t really avoid that. With a shared memory queue/ring buffer you can write to the memory without any syscalls.

But you need to build synchronisation yourself (e.g., using semaphores for example). You don’t necessarily need to poll.