pgsql: Avoid making a separate pass over the query to check for partial

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Avoid making a separate pass over the query to check for partial
Date: 2016-06-26 19:55:12
Message-ID: E1bHG9A-0000QA-UN@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Avoid making a separate pass over the query to check for partializability.

It's rather silly to make a separate pass over the tlist + HAVING qual,
and a separate set of visits to the syscache, when get_agg_clause_costs
already has all the required information in hand. This nets out as less
code as well as fewer cycles.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/f1993038a4f0ce5fbeb7b562b2acd571bf6b567b

Modified Files
--------------
src/backend/optimizer/plan/planner.c | 29 +++++----
src/backend/optimizer/util/clauses.c | 118 ++++++++++-------------------------
src/include/nodes/relation.h | 5 +-
src/include/optimizer/clauses.h | 20 ------
4 files changed, 54 insertions(+), 118 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Teodor Sigaev 2016-06-27 17:41:11 pgsql: Make exact distance match for FTS phrase operator
Previous Message Tom Lane 2016-06-26 18:33:52 pgsql: Rethink node-level representation of partial-aggregation modes.