Re: Large time difference between explain analyze and normal run

Поиск
Список
Период
Сортировка
От Chris Kratz
Тема Re: Large time difference between explain analyze and normal run
Дата
Msg-id 200502101405.46581.chris.kratz@vistashare.com
обсуждение исходный текст
Ответ на Re: Large time difference between explain analyze and normal run  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-performance
On Thursday 10 February 2005 01:58 pm, Tom Lane wrote:
> Chris Kratz <chris.kratz@vistashare.com> writes:
> > Does anyone have any idea why there be over a 4s difference between
> > running the statement directly and using explain analyze?
> >
> >  Aggregate  (cost=9848.12..9848.12 rows=1 width=0) (actual
> > time=4841.231..4841.235 rows=1 loops=1)
> >    ->  Seq Scan on answer  (cost=0.00..8561.29 rows=514729 width=0)
> > (actual time=0.011..2347.762 rows=530576 loops=1)
> >  Total runtime: 4841.412 ms
>
> EXPLAIN ANALYZE's principal overhead is two gettimeofday() kernel calls
> per plan node execution, so 1061154 such calls here.  I infer that
> gettimeofday takes about 4 microseconds on your hardware ... which seems
> a bit slow for modern machines.  What sort of box is it?
>
>             regards, tom lane

OK, that makes sense.

Athlon XP 3000+
1.5G Mem

Is there a way to test the gettimeofday() directly?

В списке pgsql-performance по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Large time difference between explain analyze and normal run
Следующее
От: Darcy Buskermolen
Дата:
Сообщение: Re: Large time difference between explain analyze and normal run