Re: That EXPLAIN ANALYZE patch still needs work - Mailing list pgsql-hackers

From Tom Lane
Subject Re: That EXPLAIN ANALYZE patch still needs work
Date
Msg-id 17395.1149714323@sss.pgh.pa.us
Whole thread Raw
In response to Re: That EXPLAIN ANALYZE patch still needs work  ("Jim C. Nasby" <jnasby@pervasive.com>)
Responses Re: That EXPLAIN ANALYZE patch still needs work  ("Jim C. Nasby" <jnasby@pervasive.com>)
List pgsql-hackers
"Jim C. Nasby" <jnasby@pervasive.com> writes:
> On Wed, Jun 07, 2006 at 11:34:30AM -0400, Tom Lane wrote:
>> timer interrupt routine does this once every few milliseconds:

> One issue is that on very fast queries, you'd get absolutely no data
> this way.

Yeah.  Of course, on "very fast" queries you don't get very good data
from the existing method either --- with a machine fast enough to have
sub-microsecond plan node execution times, the accuracy of gettimeofday
really isn't good enough.

The other thing that was bothering me was whether disk I/O might be
undercounted by an interrupt-driven method.  I kinda doubt that any
kernel will save up N interrupts that occur while the process is blocked
on a slow read() ... you'll probably get only one.  So the whole idea
may be unworkable.

At the moment I think we need to revert the recent patch and go back
to the drawing board.  Improving on the original implementation of 
EXPLAIN ANALYZE is clearly not as easy as it looks.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: That EXPLAIN ANALYZE patch still needs work
Next
From: Martijn van Oosterhout
Date:
Subject: Re: That EXPLAIN ANALYZE patch still needs work