OsPoller.create

OsPoller create() static @trusted nothrow @nogc

Create a new Linux poller.

Returns

Poller that uses io_uring when available, otherwise an epoll

fallback.

OsPoller create(bool sqpoll, uint sqThreadIdle = 20) static @trusted nothrow @nogc

Create a new Linux poller with optional SQPOLL mode.

SQPOLL uses a kernel thread to poll the submission queue, eliminating submission syscalls. Falls back to non-SQPOLL io_uring if the kernel does not support SQPOLL, and to epoll if io_uring is unavailable.

Parameters

sqpollRequest SQPOLL mode.
sqThreadIdleMilliseconds the kernel SQPOLL thread stays alive after the last submission (default: 20 ms).

Returns

Poller that uses io_uring (with SQPOLL if supported), otherwise

an epoll fallback.