perf(mdbx): fire-and-forget io_uring prefault (non-blocking)

Don't wait for io_uring completions - submit and continue immediately.
Pages will be resident by time cursor_put needs them, or soft fault handles it.
Overlaps prefault I/O with actual cursor work.
This commit is contained in:
joshieDo
2026-02-05 20:03:23 +00:00
parent 6bb0ac111d
commit 4c708d6e17

View File

@@ -15940,14 +15940,10 @@ static void subtxn_prefault_own_arena(MDBX_txn *subtxn) {
}
io_uring_submit(&ring);
struct io_uring_cqe *cqe;
for (size_t i = 0; i < npages; ++i) {
if (io_uring_wait_cqe(&ring, &cqe) < 0)
break;
io_uring_cqe_seen(&ring, cqe);
}
/* Fire-and-forget: don't wait for completions.
* Pages will be resident by time we need them, or soft fault handles it.
* This overlaps I/O with actual cursor work. */
io_uring_queue_exit(&ring);
subtxn->tw.subtxn_arena_prefaulted = true;