Re: [PERFORM] EXPLAIN ANALYZE on 8.2 - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [PERFORM] EXPLAIN ANALYZE on 8.2
Date
Msg-id 5822.1166194617@sss.pgh.pa.us
Whole thread Raw
In response to Re: [PERFORM] EXPLAIN ANALYZE on 8.2  (Martijn van Oosterhout <kleptog@svana.org>)
Responses Re: [PERFORM] EXPLAIN ANALYZE on 8.2
List pgsql-hackers
Martijn van Oosterhout <kleptog@svana.org> writes:
> On Fri, Dec 15, 2006 at 12:20:46PM +0000, Simon Riggs wrote:
>> Maybe sampling every 10 rows will bring things down to an acceptable
>> level (after the first N). You tried less than 10 didn't you?

> Yeah, it reduced the number of calls as the count got larger. It broke
> somewhere, though I don't quite remember why.

The fundamental problem with it was the assumption that different
executions of a plan node will have the same timing.  That's not true,
in fact not even approximately true.  IIRC the patch did realize
that first-time-through is not a predictor for the rest, but some of
our plan nodes have enormous variance even after the first time.
I think the worst case is batched hash joins.

            regards, tom lane

pgsql-hackers by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: [PERFORM] EXPLAIN ANALYZE on 8.2
Next
From: Tom Lane
Date:
Subject: Re: invalid input syntax for type timestamp.