Re: What about utility to calculate planner cost constants? - Mailing list pgsql-performance

From Christopher Browne
Subject Re: What about utility to calculate planner cost constants?
Date
Msg-id m34qf3aktn.fsf@knuth.knuth.cbbrowne.com
Whole thread Raw
In response to What about utility to calculate planner cost constants?  ("Tambet Matiisen" <t.matiisen@aprote.ee>)
Responses Re: What about utility to calculate planner cost constants?  (Bruno Wolff III <bruno@wolff.to>)
Re: What about utility to calculate planner cost constants?  (Greg Stark <gsstark@mit.edu>)
Re: What about utility to calculate planner cost constants?  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: What about utility to calculate planner cost constants?  (Kenneth Marshall <ktm@it.is.rice.edu>)
List pgsql-performance
Martha Stewart called it a Good Thing when gsstark@mit.edu (Greg Stark) wrote:
> I don't think it would be very hard at all actually.
>
> It's just a linear algebra problem with a bunch of independent
> variables and a system of equations. Solving for values for all of
> them is a straightforward problem.
>
> Of course in reality these variables aren't actually independent
> because the costing model isn't perfect. But that wouldn't be a
> problem, it would just reduce the accuracy of the results.

Are you certain it's a linear system?  I'm not.  If it was a matter of
minimizing a linear expression subject to some set of linear
equations, then we could model this as a Linear Program for which
there are some perfectly good solvers available.  (Few with BSD-style
licenses, but we could probably get some insight out of running for a
while with something that's there...)

I think there's good reason to consider it to be distinctly
NON-linear, which makes it way more challenging to solve the problem.

There might well be some results to be gotten out of a linear
approximation; the Grand Challenge is to come up with the model in the
first place...
--
wm(X,Y):-write(X),write('@'),write(Y). wm('cbbrowne','gmail.com').
http://linuxdatabases.info/info/or.html
"Tom Christiansen  asked me,  "Chip, is there  anything that  you like
that isn't big and complicated?" C++, EMACS, Perl, Unix, English-no, I
guess not." -- Chip Salzenberg, when commenting on Perl6/C++

pgsql-performance by date:

Previous
From: Rick Jansen
Date:
Subject: Re: Tsearch2 performance on big database
Next
From: Alex Turner
Date:
Subject: Planner issue