| From: | Alexander Nestorov <alexandernst(at)gmail(dot)com> |
|---|---|
| To: | Maxime Schoemans <maxime(dot)schoemans(at)enterprisedb(dot)com> |
| Cc: | Andrey Borodin <x4mmm(at)yandex-team(dot)ru>, pgsql-hackers mailing list <pgsql-hackers(at)postgresql(dot)org> |
| Subject: | Re: [PATCH] btree_gist: add cross-type integer operator support for GiST |
| Date: | 2026-06-23 22:53:47 |
| Message-ID: | ac05a661-53a5-478a-9907-f56a960dab51@Spark |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Hey Maxime!
Thank you for reviewing my changes so far and for proposing the changes in your
patch! And thank you for the kind words!
1)
I think we still need to check `InvalidOid` because execIndexing.c:~800
initializes scan keys ('ScanKeyEntryInitialize') with `InvalidOid` as the
subtype. Running the 'not_equal', 'partitions' and 'without_overlaps' tests
confirms that 'InvalidOid' must be handled. I can add the check again in the
switch. (attaching patch)
2) and 3)
I completely agree, your patch makes it much cleaner.
I applied your patch (with the 'InvalidOid' fix) on top of mine and ran all the
tests and benchmarks that I prepared previously. These are the results before
the entire patchset and after:
duration=15s/run, reps=10, 1 client, interleaved, lower is better
------------------------------------------------------------------------
before consistent min/med/mean = 51.246 51.361 51.378 ms
after consistent min/med/mean = 51.849 51.958 51.967 ms
------------------------------------------------------------------------
before distance min/med/mean = 76.441 76.561 76.567 ms
after distance min/med/mean = 76.568 76.678 76.681 ms
------------------------------------------------------------------------
I added one more commit that adds a small description of this fix in the docs.
The current patchset has been rebased on top of ef01ca6dbca54e9bf3abea01c357b346847ebcf3
Best regards!
| Attachment | Content-Type | Size |
|---|---|---|
| v4-0001-Implement-cross-type-operators-for-GiST-indexes.patch | application/octet-stream | 26.4 KB |
| v4-0002-Add-tests-for-cross-type-operators-for-GiST-indexes.patch | application/octet-stream | 23.9 KB |
| v4-0003-Add-docs-for-cross-type-operators-for-GiST-indexes.patch | application/octet-stream | 2.4 KB |
| v4-0004-Reuse-gbt_num_consistent-for-cross-type-integer-comp.patch | application/octet-stream | 32.9 KB |
| v4-0005-Safe-guard-InvalidOid.patch | application/octet-stream | 4.4 KB |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Jacob Champion | 2026-06-23 22:54:17 | Re: Heads Up: cirrus-ci is shutting down June 1st |
| Previous Message | Bharath Rupireddy | 2026-06-23 22:40:12 | Re: Fix race condition in pg_get_publication_tables with concurrent DROP TABLE |