Re: [WIP]Vertical Clustered Index (columnar store extension) - take2 - Mailing list pgsql-hackers

From Timur Magomedov
Subject Re: [WIP]Vertical Clustered Index (columnar store extension) - take2
Date
Msg-id 07c53a696afb8089d724214dbaeded6fcaa8fc0d.camel@postgrespro.ru
Whole thread Raw
In response to Re: [WIP]Vertical Clustered Index (columnar store extension) - take2  (Peter Smith <smithpb2250@gmail.com>)
List pgsql-hackers
On Thu, 2025-08-14 at 11:23 +1000, Peter Smith wrote:
> Here are the latest v18* patches.
>

Hi Peter!
I've reworked my recent patch [1] so it is now based on v18 and is
divided into several simpler patches. Here they are plus one additional
patch.

0001-Fixed-comment-and-guard-name-in-vci_pg_copy.h.patch
Looks like vci_pg_copy.h was renamed from vci_numeric.h but file name
comment and define guard name were not updated. Fixed it.

0002-Removed-vci_set_merge_and_copy_trans_funcs.patch
Found that vci_set_merge_and_copy_trans_funcs() is not used anywhere,
removed it alogn with the code that was only called inside it.
trans_funcs_table[] now only contains single transfn_oid field, others
(unused) are removed.

0003-Replaced-linear-search-by-switch-case.patch
Replaced linear search inside trans_funcs_table array to more optimal
switch-case.

0004-Removed-worker-name-check-in-lock.c.patch
This is one I'm not sure about.
Found that changes in Postgres core lock.c file check for "backend="
substring in background worker name. There is also a comment in
vci_ros_daemon.c mentioning bgw_name checks of LockAquire(). Names
don't match however. So as far as I understand the check for "backend="
in name is always false since no code in VCI sets bgw_name to something
similar.
This is either forgotten feature that can be easily fixed by removing
bgw_name checks, either some bug, either my misunderstanding.
For the first case, here is a patch that removes bgw_name checks in
lock.c. It makes core patch a bit smaller and not touching lock.c at
all (Yay!).

[1]
https://www.postgresql.org/message-id/8beac6e8a01971b22ccf0f2e2a8eb12a78e5a7ac.camel%40postgrespro.ru

--
Regards,
Timur Magomedov


Attachment

pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: Remove Instruction Synchronization Barrier in spin_delay() for ARM64 architecture
Next
From: Nathan Bossart
Date:
Subject: Re: Remove Instruction Synchronization Barrier in spin_delay() for ARM64 architecture