odd variances in count(*) times

Поиск
Список
Период
Сортировка
От Merlin Moncure
Тема odd variances in count(*) times
Дата
Msg-id b42b73150610091117n29e8d9d5yed07abe8a228593e@mail.gmail.com
обсуждение исходный текст
Ответы Re: odd variances in count(*) times  (Stephen Frost <sfrost@snowman.net>)
Список pgsql-performance
I have two systems running 8.2beta1 getting strange difference of
results in count(*).  Query that illistrates the difference is
count(*).  this is a synthetic test i use to measure a sytems's cpu
performance.

System A:
2.2 ghz p4 northwood, HT
win xp
vanilla sata (1 disk)

System B:
amd 64 3700+
linux cent/os 4.4 32 bit
4 raptors, raid 5, 3ware

explain analyze select 5000!;
A: 2.4 seconds
B: 1.8 seconds

explain analyze select count(*) from generate_series(1,500000);
A: 0.85 seconds
B: 4.94 seconds

Both systems have a freshly minted database.  By all resepcts I would
expect B to outperform A on most cpu bound tests with a faster
processor and linux kernel.  memory is not an issue here, varying the
size of the count(*) does not effect the results, A is always 5x
faster than B.  the only two variables i see are cpu and o/s.

Also tested on pg 8.1, results are same except pg 8.2 is about 10%
faster on both systems for count(*).  (yay!) :-)

anybody think of anything obvious? should i profile? (windows mingw
profiling sucks)

merlin

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Simple join optimized badly?
Следующее
От: Stephen Frost
Дата:
Сообщение: Re: odd variances in count(*) times