Re: KNN-GiST with recheck

Поиск
Список
Период
Сортировка
От Alexander Korotkov
Тема Re: KNN-GiST with recheck
Дата
Msg-id CAPpHfduGjVpTLVxwXmeMuFqR-ykH-ERdewF-KHxSQiRdw29-7g@mail.gmail.com
обсуждение исходный текст
Ответ на Re: KNN-GiST with recheck  (Alexander Korotkov <aekorotkov@gmail.com>)
Ответы Re: KNN-GiST with recheck  (Tomas Vondra <tomas.vondra@2ndquadrant.com>)
Список pgsql-hackers
On Sun, Feb 15, 2015 at 2:08 PM, Alexander Korotkov <aekorotkov@gmail.com> wrote:
Following changes has been made in attached patch:

 * Get sort operators from pathkeys.
 * Recheck argument of distance function has been reverted.

Few comments were added and pairing heap comparison function was fixed in attached version of patch (knn-gist-recheck-6.patch).
Also I expected that reordering in executor would be slower than reordering in GiST because of maintaining two heaps instead of one. I've revised version of patch with reordering in GiST to use pairing heap. I compare two types of reordering on 10^7 random points and polygons. Results are below. Test shows that overhead of reordering in executor is insignificant (less than statistical error). 

             Reorder in GiST   Reorder in executor      
points
limit=10     0.10615           0.0880125
limit=100    0.23666875        0.2292375
limit=1000   1.51486875        1.5208375
polygons
limit=10     0.11650625        0.1347
limit=100    0.46279375        0.45294375
limit=1000   3.5170125         3.54868125

Revised patch with reordering in GiST is attached (knn-gist-recheck-in-gist.patch) as well as testing script (test.py).

------
With best regards,
Alexander Korotkov.

Вложения

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Tim Kane
Дата:
Сообщение: Re: postgres_fdw foreign keys with default sequence
Следующее
От: Oskari Saarenmaa
Дата:
Сообщение: Re: __attribute__ for non-gcc compilers