SIGN IN SIGN UP

Add `setup_no_sqarray` builder method (#384)

* Add `setup_no_sqarray` builder method.

This exposes `IORING_SETUP_NO_SQARRAY` (available since Linux 6.6) which
removes the SQ index array indirection, eliminating a memory read per
submission.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Fix NO_SQARRAY ring header corruption.

When IORING_SETUP_NO_SQARRAY is set, the kernel sets sq_off.array to 0.
The SQ array initialization loop was writing to offset 0 of the SQ mmap,
corrupting the ring header (sq_head, sq_tail, etc.). Skip the array
initialization when NO_SQARRAY is set since the kernel consumes SQEs
directly by ring index.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Add test for setup_no_sqarray.

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
D
David Yamnitsky committed
d7008ee94de8282a4db27419df327e12344dd880
Parent: b405b48
Committed by GitHub <noreply@github.com> on 4/18/2026, 4:21:00 AM