mirror of
https://github.com/zebrajr/postgres.git
synced 2026-01-15 12:15:21 +00:00
Add support for basic NUMA awareness
Add basic NUMA awareness routines, using a minimal src/port/pg_numa.c portability wrapper and an optional build dependency, enabled by --with-libnuma configure option. For now this is Linux-only, other platforms may be supported later. A built-in SQL function pg_numa_available() allows checking NUMA support, i.e. that the server was built/linked with the NUMA library. The main function introduced is pg_numa_query_pages(), which allows determining the NUMA node for individual memory pages. Internally the function uses move_pages(2) syscall, as it allows batching, and is more efficient than get_mempolicy(2). Author: Jakub Wartak <jakub.wartak@enterprisedb.com> Co-authored-by: Bertrand Drouvot <bertranddrouvot.pg@gmail.com> Reviewed-by: Andres Freund <andres@anarazel.de> Reviewed-by: Álvaro Herrera <alvherre@alvh.no-ip.org> Reviewed-by: Tomas Vondra <tomas@vondra.me> Discussion: https://postgr.es/m/CAKZiRmxh6KWo0aqRqvmcoaX2jUxZYb4kGp3N%3Dq1w%2BDiH-696Xw%40mail.gmail.com
This commit is contained in:
@@ -471,6 +471,7 @@ task:
|
||||
--enable-cassert --enable-injection-points --enable-debug \
|
||||
--enable-tap-tests --enable-nls \
|
||||
--with-segsize-blocks=6 \
|
||||
--with-libnuma \
|
||||
--with-liburing \
|
||||
\
|
||||
${LINUX_CONFIGURE_FEATURES} \
|
||||
@@ -523,6 +524,7 @@ task:
|
||||
-Dllvm=disabled \
|
||||
--pkg-config-path /usr/lib/i386-linux-gnu/pkgconfig/ \
|
||||
-DPERL=perl5.36-i386-linux-gnu \
|
||||
-Dlibnuma=disabled \
|
||||
build-32
|
||||
EOF
|
||||
|
||||
|
||||
Reference in New Issue
Block a user