Re: pg_stat_progress_create_index vs. parallel index builds

Поиск
Список
Период
Сортировка
От Greg Nancarrow
Тема Re: pg_stat_progress_create_index vs. parallel index builds
Дата
Msg-id CAJcOf-dSZAjnvjQUjniEa+aA7k6ed-fOmafjvaQd5Djw1NN3Ow@mail.gmail.com
обсуждение исходный текст
Ответ на Re: pg_stat_progress_create_index vs. parallel index builds  (Greg Nancarrow <gregn4422@gmail.com>)
Список pgsql-hackers
On Fri, Jun 4, 2021 at 5:25 PM Greg Nancarrow <gregn4422@gmail.com> wrote:
>
> What is slightly puzzling to me (and perhaps digging deeper will
> reveal it) is why this "sorting live tuples" phase seems so short in
> the serial case compared to the parallel case?
> For example, in my test I created an index on a column of a table
> having 10 million records, and it took about 40 seconds, during which
> the "sorting live tuples" phase seemed to take about 8 seconds. Yet
> for the serial case, index creation took about 75 seconds, during
> which the "sorting live tuples" phase seemed to take about 1 second.
>

Seems to be because in the serial case, the sort occurs after the scan
is complete (obviously) but in the parallel case, the scan and sort
are combined, so (after patch application) a portion of the then
reported "sorting live tuples" phase is actually "scanning table".

Regards,
Greg Nancarrow
Fujitsu Australia



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

Предыдущее
От: Fabien COELHO
Дата:
Сообщение: Re: Failures with gcd functions with GCC snapshots GCC and -O3 (?)
Следующее
От: "Joel Jacobson"
Дата:
Сообщение: Re: security_definer_search_path GUC