Re: WIP Patch: Precalculate stable functions, infrastructure v1

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: WIP Patch: Precalculate stable functions, infrastructure v1
Дата
Msg-id 16703.1516824656@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: WIP Patch: Precalculate stable functions, infrastructure v1  (Andres Freund <andres@anarazel.de>)
Ответы Re: WIP Patch: Precalculate stable functions, infrastructure v1
Список pgsql-hackers
Andres Freund <andres@anarazel.de> writes:
> On 2018-01-16 17:05:01 -0500, Tom Lane wrote:
>> I'm curious to know whether Andres has some other ideas, or whether he
>> feels this is all a big wart on the compiled-expression concept.

> I don't have too many "artistic" concerns from the compiled expression
> POV. The biggest issue I see is that it'll make it a bit harder to
> separate out the expression compilation phase from the expression
> instantiation phase - something I think we definitely want.

Hmm, there's no such distinction now, so could you explain what you
have in mind there?

>> I don't think there are any existing cases where we keep any
>> meaningful state across executions of a compiled-expression data
>> structure; maybe that's a bad idea in itself.

> Storing all cached values in an EState or ExprContext (the
> latter referring to the former) somewhat alike the values for Param's
> sounds a lot more reasonable to me.
> ...
> This all reminds me a lot of the infrastructure for Params...

Yeah, one thing I was thinking about in connection with this is the
stuff associated with propagating changes in outer-reference Params
(the extParam/allParam/chgParam mess).  I wonder if we could find
a way to unify that with this feature.

Keeping the stored value of a CachedExpr in a Param slot is an
interesting idea indeed.

            regards, tom lane


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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: pgsql: Add parallel-aware hash joins.
Следующее
От: Thomas Munro
Дата:
Сообщение: Re: [HACKERS] Parallel tuplesort (for parallel B-Tree index creation)