Re: [HACKERS] Cached plans and statement generalization

Поиск
Список
Период
Сортировка
От Konstantin Knizhnik
Тема Re: [HACKERS] Cached plans and statement generalization
Дата
Msg-id 5914C00A.9030908@postgrespro.ru
обсуждение исходный текст
Ответ на Re: [HACKERS] Cached plans and statement generalization  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: [HACKERS] Cached plans and statement generalization  (Andres Freund <andres@anarazel.de>)
Список pgsql-hackers
On 05/11/2017 09:31 PM, Tom Lane wrote:
> Bruce Momjian <bruce@momjian.us> writes:
>> Good point.  I think we need to do some measurements to see if the
>> parser-only stage is actually significant.  I have a hunch that
>> commercial databases have much heavier parsers than we do.
> FWIW, gram.y does show up as significant in many of the profiles I take.
> I speculate that this is not so much that it eats many CPU cycles, as that
> the constant tables are so large as to incur lots of cache misses.  scan.l
> is not quite as big a deal for some reason, even though it's also large.
>
>             regards, tom lane
Yes, my results shows that pg_parse_query adds not so much overhead:
206k TPS for my first variant with string literal substitution and modified query text used as hash key vs.
181k. TPS for version with patching raw parse tree constructed by pg_parse_query.


-- 
Konstantin Knizhnik
Postgres Professional: http://www.postgrespro.com
The Russian Postgres Company




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

Предыдущее
От: Konstantin Knizhnik
Дата:
Сообщение: Re: [HACKERS] Cached plans and statement generalization
Следующее
От: Tom Lane
Дата:
Сообщение: Re: [HACKERS] WITH clause in CREATE STATISTICS