Re: Add 64-bit XIDs into PostgreSQL 15

Robert Haas <robertmhaas@gmail.com>

From: Robert Haas <robertmhaas@gmail.com>
To: Heikki Linnakangas <hlinnaka@iki.fi>
Cc: Maxim Orlov <orlovmg@gmail.com>, Yura Sokolov <y.sokolov@postgrespro.ru>, Evgeny Voropaev <evgeny.voropaev@tantorlabs.com>, PostgreSQL Hackers <pgsql-hackers@postgresql.org>, Andrey Borodin <x4mmm@yandex-team.ru>
Date: 2026-02-08T01:30:41Z
Lists: pgsql-hackers
On Sat, Feb 7, 2026 at 5:47 PM Heikki Linnakangas <hlinnaka@iki.fi> wrote:
> The thing I like least about this is how the upgrade works, i.e. the
> conversion code and the "double xmax" hack. This would look much nicer
> if we could start from clean slate and just add the fields we need to
> the page header. However, upgrade is important, that point has been
> discussed a lot on the list, and I don't have any better ideas. I think
> it's as good as it gets at the high level.

I don't think the page header is the right thing, because that applies
to every AM, including both table AMs and index AMs. I'd say that some
of the things we already have in the page header don't really make
sense there -- in particular, pd_prune_xid, which is heap-specific. We
can't change that at this point, but we shouldn't make it worse.

-- 
Robert Haas
EDB: http://www.enterprisedb.com



Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. Add SLRU tests for 64-bit page case

  2. Make use FullTransactionId in 2PC filenames

  3. Use larger segment file names for pg_notify

  4. Index SLRUs by 64-bit integers rather than by 32-bit integers