pgsql: Rationalize expression context reset in ExecModifyTable().

Поиск
Список
Период
Сортировка
От Andres Freund
Тема pgsql: Rationalize expression context reset in ExecModifyTable().
Дата
Msg-id E1gNNZW-0006sv-HH@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Rationalize expression context reset in ExecModifyTable().

The current pattern of reseting expressions both in
ExecProcessReturning() and ExecOnConflictUpdate() makes it harder than
necessary to reason about memory lifetimes.  It also requires
materializing slots unnecessarily, although this patch doesn't take
advantage of the fact that that's not necessary anymore.

Instead reset the expression context once for each input tuple.

Author: Ashutosh Bapat
Discussion: https://postgr.es/m/20181105210039.hh4vvi4vwoq5ba2q@alap3.anarazel.de

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/c058fc2a2b8ea25015b211186c88a6a3006f5937

Modified Files
--------------
src/backend/executor/nodeModifyTable.c | 22 +++++++++-------------
1 file changed, 9 insertions(+), 13 deletions(-)


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

Предыдущее
От: Andres Freund
Дата:
Сообщение: pgsql: Make reformat-dat-files, reformat-dat-files VPATH safe.
Следующее
От: Peter Eisentraut
Дата:
Сообщение: pgsql: Correct code comments for PartitionedRelPruneInfo struct