Re: Adding basic NUMA awareness

Tomas Vondra <tomas@vondra.me>

From: Tomas Vondra <tomas@vondra.me>
To: Jakub Wartak <jakub.wartak@enterprisedb.com>
Cc: Alexey Makhmutov <a.makhmutov@postgrespro.ru>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>, Andres Freund <andres@anarazel.de>
Date: 2025-11-21T18:49:25Z
Lists: pgsql-hackers

Attachments

Hi,

Here's an updated version of the patch series.

It fixes a bunch of issues in pg_buffercache_pages.c - duplicate attnums
and a incorrect array length.

The main change is in 0006 - it sets the default allocation policy for
shmem to interleaving, before doing the explicit partitioning for shared
buffers. It does it by calling numa_set_membind before the mmap(), and
then numa_interleave_memory() on the allocated shmem. It does this to
allow using MAP_POPULATE - but that's commented out by default.

This does seem to solve the SIGBUS failures for me. I still think there
might be a small chance of hitting that, because of locating an extra
"boundary" page on one of the nodes. But it should be solvable by
reserving a couple more pages.

Jakub, what do you think?


regards

-- 
Tomas Vondra

Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. Sort guc_parameters.dat alphabetically by name