Re: WIP: parallel GiST index builds
Tomas Vondra <tomas@vondra.me>
From: Tomas Vondra <tomas@vondra.me>
To: "Andrey M. Borodin" <x4mmm@yandex-team.ru>
Cc: Andreas Karlsson <andreas@proxel.se>,
PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2024-08-05T15:18:52Z
Lists: pgsql-hackers
Attachments
- v20240805-0001-WIP-parallel-GiST-build.patch (text/x-patch) patch v20240805-0001
- v20240805-0002-use-GetFakeLSNForUnloggedRel.patch (text/x-patch) patch v20240805-0002
Hi, Here's an updated patch using GetFakeLSNForUnloggedRel() instead of the atomic counter. I think this looks much nicer and less invasive, as it simply uses XLogCtl shared memory (instead of having to pass a new pointer everywhere). We still need to pass the is_parallel flag, though. I wonder if we could get rid of that too, and just use GetFakeLSNForUnloggedRel() for both parallel and non-parallel builds? Why wouldn't that work? I've spent quite a bit of time testing this, but mostly for correctness. I haven't redone the benchmarks, that's on my TODO. regards -- Tomas Vondra