Re: pgsql-server/src/backend/utils/sort tuplesort.c

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: pgsql-server/src/backend/utils/sort tuplesort.c
Дата
Msg-id 3177.1079570221@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: pgsql-server/src/backend/utils/sort tuplesort.c  (Bruce Momjian <pgman@candle.pha.pa.us>)
Ответы Re: pgsql-server/src/backend/utils/sort tuplesort.c  (Bruce Momjian <pgman@candle.pha.pa.us>)
Список pgsql-committers
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> Tom Lane wrote:
>> During btree index build, sort equal-keyed tuples according to their
>> TID (heap position).  This doesn't do anything to the validity of the
>> finished index, but by pretending to qsort() that there are no really
>> equal keys in the sort, we can avoid performance problems with qsort
>> implementations that have trouble with large numbers of equal keys.
>> Patch from Manfred Koizar.

> I think there is also the advantage that many equal keys will access the
> heap in a more sequential, rather than random, order, which is the part
> that really excited me.

But we aren't attempting to maintain that ordering after index build.
(In fact, it was exactly that point that triggered the argument last
time round ...)

            regards, tom lane

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: pgsql-server/src/backend/utils/sort tuplesort.c
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: pgsql-server/src/backend/utils/sort tuplesort.c