Re: Function execution costs 'n all that

From: Ron Mayer <rm_pg(at)cheapcomplexdevices(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: Function execution costs 'n all that
Date: 2007-01-17 20:07:36
Message-ID: 45AE8208.9000206@cheapcomplexdevices.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:
>
> BTW, I'm thinking that a "cost constant" probably ought to be measured
> in units of cpu_operator_cost. The default for built-in functions would
> thus be 1, at least till such time as someone wants to refine the
> estimates. We'd probably want the default for PL and SQL functions to
> be 10 or 100 or so.

Any chance that costs could eventually change to real-world units?

It's hard for me to guess how many cpu_operator_cost units
something might take; but relatively easy for me to measure
or estimate in fractions-of-a-seconds how long something takes.

I could imagine having the other planner costs be measured in seconds
too - perhaps with the goal of eventually writing some auto-config
code that tries to measure values like cpu_tuple_cost on a given
piece of hardware.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2007-01-17 20:13:26 Re: Function execution costs 'n all that
Previous Message Magnus Hagander 2007-01-17 20:00:35 Re: Idea for fixing the Windows fsync problem