Re: hashagg slowdown due to spill changes

Поиск
Список
Период
Сортировка
От Jeff Davis
Тема Re: hashagg slowdown due to spill changes
Дата
Msg-id a2fb7dfeb4f50aa0a123e42151ee3013933cb802.camel@j-davis.com
обсуждение исходный текст
Ответ на Re: hashagg slowdown due to spill changes  (Robert Haas <robertmhaas@gmail.com>)
Ответы Re: hashagg slowdown due to spill changes  (Tomas Vondra <tomas.vondra@2ndquadrant.com>)
Re: hashagg slowdown due to spill changes  (Andres Freund <andres@anarazel.de>)
Список pgsql-hackers
On Mon, 2020-06-15 at 11:19 -0400, Robert Haas wrote:
> On Mon, Jun 15, 2020 at 9:34 AM Tomas Vondra
> <tomas.vondra@2ndquadrant.com> wrote:
> > But just reverting 4cad2534d will make this much worse, I think, as
> > illustrated by the benchmarks I did in [1].
> 
> I share this concern, although I do not know what we should do about
> it.

I attached an updated version of Melanie's patch, combined with the
changes to copy only the necessary attributes to a new slot before
spilling. There are a couple changes:

* I didn't see a reason to descend into a GroupingFunc node, so I
removed that.

* I used a flag in the context rather than two separate callbacks to
the expression walker.

This patch gives the space benefits that we see on master, without the
regression for small numbers of tuples. I saw a little bit of noise in
my test results, but I'm pretty sure it's a win all around. It could
use some review/cleanup though.

Regards,
    Jeff Davis


Вложения

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

Предыдущее
От: Ranier Vilela
Дата:
Сообщение: Re: Failures with wal_consistency_checking and 13~
Следующее
От: Ranier Vilela
Дата:
Сообщение: Re: Postgresql13_beta1 (could not rename temporary statistics file)Windows 64bits