VALUES clause memory optimization (was: Values list-of-targetlists patch...)

From: Joe Conway <mail(at)joeconway(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "Hackers (PostgreSQL)" <pgsql-hackers(at)postgresql(dot)org>
Subject: VALUES clause memory optimization (was: Values list-of-targetlists patch...)
Date: 2006-08-03 00:18:39
Message-ID: 44D140DF.5080209@joeconway.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-docs pgsql-hackers pgsql-patches

Tom Lane wrote:
> I think we could safely list_free the input list in transformInsertRow
> as your patch suggests, which would buy back the 144M part. But I don't
> believe it's safe at all to free the raw_parser output --- the grammar
> sometimes makes multiple links to the same subtree, eg in BETWEEN.

In transformExpr the comment implies that it should be safe to reapply
to an already transformed expression. What if we free the raw_parser
expression list/cells/nodes and replace it with the as-transformed one?

Joe

In response to

Responses

Browse pgsql-docs by date

  From Date Subject
Next Message Gavin Sherry 2006-08-03 05:31:06 Re: Values list-of-targetlists patch for comments (was Re:
Previous Message Tom Lane 2006-08-02 19:18:26 Re: Values list-of-targetlists patch for comments (was Re:

Browse pgsql-hackers by date

  From Date Subject
Next Message Andreas Pflug 2006-08-03 00:48:08 pg_terminate_backend
Previous Message Andreas Seltenreich 2006-08-02 23:35:05 GIN vs. statistics collector

Browse pgsql-patches by date

  From Date Subject
Next Message Gavin Sherry 2006-08-03 05:31:06 Re: Values list-of-targetlists patch for comments (was Re:
Previous Message Andreas Seltenreich 2006-08-02 23:35:05 GIN vs. statistics collector