Re: [PATCH] Equivalence Class Filters

From: Jim Nasby <Jim(dot)Nasby(at)BlueTreble(dot)com>
To: Simon Riggs <simon(at)2ndQuadrant(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: David Rowley <david(dot)rowley(at)2ndquadrant(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [PATCH] Equivalence Class Filters
Date: 2015-12-07 16:55:15
Message-ID: 5665B9F3.80109@BlueTreble.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 12/7/15 10:44 AM, Simon Riggs wrote:
> There are many optimizations we might adopt, yet planning time is a
> factor. It seems simple enough to ignore more complex optimizations if
> we have already achieved a threshold cost (say 10). Such a test would
> add nearly zero time for the common case. We can apply the optimizations
> in some kind of ordering depending upon the cost, so we are careful to
> balance the cost/benefit of trying certain optimizations.

Unfortunately I've seen a lot of millisecond queries that have 6 figure
estimates, due to data being in cache. So I'm not sure how practical
that would be.

Maybe a better starting point would be a planner timeout.

I definitely agree we need some method to limit planning time when
necessary (ie: OLTP). Without that we'll never be able to start testing
more complex optimizations.
--
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Experts in Analytics, Data Architecture and PostgreSQL
Data in Trouble? Get it in Treble! http://BlueTreble.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2015-12-07 17:01:23 Re: Foreign join pushdown vs EvalPlanQual
Previous Message Jim Nasby 2015-12-07 16:48:08 Re: [PATCH] Equivalence Class Filters