Re: calling procedures is slow and consumes extra much memory againstcalling function

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема Re: calling procedures is slow and consumes extra much memory againstcalling function
Дата
Msg-id CAFj8pRAMHei7eWOkCTsiKxh3BPUaCbJFuVySn+R+Qk9dfNOFTw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: calling procedures is slow and consumes extra much memory againstcalling function  (Pavel Stehule <pavel.stehule@gmail.com>)
Ответы Re: calling procedures is slow and consumes extra much memory againstcalling function  (Amit Khandekar <amitdkhan.pg@gmail.com>)
Список pgsql-hackers
Hi
 
The problem is in plpgsql implementation of CALL statement

In non atomic case -  case of using procedures from DO block, the expression plan is not cached, and plan is generating any time. This is reason why it is slow.

Unfortunately, generated plans are not released until SPI_finish. Attached patch fixed this issue.

But now, recursive calling doesn't work :-(. So this patch is not enough

Attached patch is working - all tests passed

It doesn't solve performance, and doesn't solve all memory problems, but significantly reduce memory requirements from 5007 bytes to 439 bytes per one CALL

Regards

Pavel




Regards

Pavel


Regards

Pavel

Вложения

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

Предыдущее
От: Shichao Jin
Дата:
Сообщение: Spawned Background Process Knows the Exit of Client Process?
Следующее
От: Christopher Baines
Дата:
Сообщение: [PATCH] Fix pg_dump --no-tablespaces for the custom format