public inbox for [email protected]
help / color / mirror / Atom feedpgsql: aio: Add io_method=io_uring
2+ messages / 1 participants
[nested] [flat]
* pgsql: aio: Add io_method=io_uring
@ 2025-03-27 00:15 Andres Freund <[email protected]>
0 siblings, 1 reply; 2+ messages in thread
From: Andres Freund @ 2025-03-27 00:15 UTC (permalink / raw)
To: [email protected]
aio: Add io_method=io_uring
Performing AIO using io_uring can be considerably faster than
io_method=worker, particularly when lots of small IOs are issued, as
a) the context-switch overhead for worker based AIO becomes more significant
b) the number of IO workers can become limiting
io_uring, however, is linux specific and requires an additional compile-time
dependency (liburing).
This implementation is fairly simple and there are substantial optimization
opportunities.
The description of the existing AIO_IO_COMPLETION wait event is updated to
make the difference between it and the new AIO_IO_URING_EXECUTION clearer.
Reviewed-by: Noah Misch <[email protected]>
Reviewed-by: Jakub Wartak <[email protected]>
Discussion: https://postgr.es/m/uvrtrknj4kdytuboidbhwclo4gxhswwcpgadptsjvjqcluzmah%40brqs62irg4dt
Discussion: https://postgr.es/m/[email protected]
Discussion: https://postgr.es/m/stj36ea6yyhoxtqkhpieia2z4krnam7qyetc57rfezgk4zgapf@gcnactj4z56m
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/c325a7633fcb33dbd73f46ddbbe91e95ddf3b227
Modified Files
--------------
.cirrus.tasks.yml | 3 +
doc/src/sgml/config.sgml | 8 +
src/backend/storage/aio/Makefile | 1 +
src/backend/storage/aio/aio.c | 41 ++
src/backend/storage/aio/aio_io.c | 22 ++
src/backend/storage/aio/meson.build | 1 +
src/backend/storage/aio/method_io_uring.c | 484 ++++++++++++++++++++++++
src/backend/storage/lmgr/lwlock.c | 1 +
src/backend/utils/activity/wait_event_names.txt | 4 +-
src/backend/utils/misc/postgresql.conf.sample | 3 +-
src/include/storage/aio.h | 8 +
src/include/storage/aio_internal.h | 13 +
src/include/storage/lwlock.h | 1 +
src/tools/pgindent/typedefs.list | 1 +
14 files changed, 589 insertions(+), 2 deletions(-)
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: pgsql: aio: Add io_method=io_uring
@ 2025-03-27 01:11 Andres Freund <[email protected]>
parent: Andres Freund <[email protected]>
0 siblings, 0 replies; 2+ messages in thread
From: Andres Freund @ 2025-03-27 01:11 UTC (permalink / raw)
To: [email protected]
Hi,
On 2025-03-27 00:15:53 +0000, Andres Freund wrote:
> aio: Add io_method=io_uring
FWIW, the BF failure on culicidae looks to be independent to me
https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=culicidae&dt=2025-03-27%2000%3A16%3A30
The relevant line from the log is:
2025-03-27 00:20:05.478 UTC [353525][not initialized][:0] FATAL: incorrect checksum in control file
See also
https://postgr.es/m/7ff9de7f-7203-cad9-76d9-45497cbedac7%40gmail.com
Greetings,
Andres Freund
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2025-03-27 01:11 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2025-03-27 00:15 pgsql: aio: Add io_method=io_uring Andres Freund <[email protected]>
2025-03-27 01:11 ` Andres Freund <[email protected]>
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox