Re: Yet another fast GiST build - Mailing list pgsql-hackers

From Andrey Borodin
Subject Re: Yet another fast GiST build
Date
Msg-id 3EEE9A86-66A7-4D55-8EFF-70CA5D43AD8E@yandex-team.ru
Whole thread Raw
In response to Re: Yet another fast GiST build  (Alexander Korotkov <a.korotkov@postgrespro.ru>)
Responses Re: Yet another fast GiST build  (Andrey Borodin <x4mmm@yandex-team.ru>)
Re: Yet another fast GiST build  (Alexander Korotkov <a.korotkov@postgrespro.ru>)
List pgsql-hackers


30 авг. 2019 г., в 3:47, Alexander Korotkov <a.korotkov@postgrespro.ru> написал(а):

1) Binary search in non-leaf pages instead of probing each key is much faster.

That's a neat idea, but key union breaks ordering, even for z-order.
for two sets of tuples X and Y
if for any i,o from N, Xi < Yo
does not guaranty union(X) < union (Y) 

For example consider this z-ordered keyspace (picture attached)

union(5, 9) is z-order-smaller than union(4,4)

I'm not even sure we can use sorted search for choosing subtree for insertion.

How do you think, should I supply GiST-build patch with docs and tests and add it to CF? Or do we need more design discussion before?


Best regards, Andrey Borodin.
Attachment

pgsql-hackers by date:

Previous
From: Jeevan Ladhe
Date:
Subject: Re: basebackup.c's sendFile() ignores read errors
Next
From: Fabien COELHO
Date:
Subject: Re: WIP: Generic functions for Node types using generated metadata