Re: POC: converting Lists into arrays

Поиск
Список
Период
Сортировка
От Andres Freund
Тема Re: POC: converting Lists into arrays
Дата
Msg-id 20190304190327.n2g53f4ap7l4zusq@alap3.anarazel.de
обсуждение исходный текст
Ответ на Re: POC: converting Lists into arrays  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Hi,

On 2019-03-03 13:29:04 -0500, Tom Lane wrote:
> The cases I've been looking at suggest to me that we'd make far
> more progress on the excessive-palloc'ing front if we could redesign
> things to reduce unnecessary copying of parsetrees.  Right now the
> planner does an awful lot of copying because of fear of unwanted
> modifications of multiply-linked subtrees.  I suspect that we could
> reduce that overhead with some consistently enforced rules about
> not scribbling on input data structures; but it'd take a lot of work
> to get there, and I'm afraid it'd be easily broken :-(

Given the difficulty of this tasks, isn't your patch actually a *good*
attack on the problem? It makes copying lists considerably cheaper. As
you say, a more principled answer to this problem is hard, so attacking
it from the "make the constant factors smaller" side doesn't seem crazy?

Greetings,

Andres Freund


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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: POC: converting Lists into arrays
Следующее
От: Andres Freund
Дата:
Сообщение: Re: POC: converting Lists into arrays