Документ взят из кэша поисковой машины. Адрес оригинального документа : http://www.sai.msu.su/~megera/oddmuse/index.cgi/Bench
Дата изменения: Unknown
Дата индексирования: Mon Apr 11 03:31:43 2016
Кодировка:
Zen: Bench

Bench

Scripts
Prerequisities
  • Postgresql 7.3 and above with access statistics collection enabled in postgresql.conf:
#
#       Access statistics collection
#
#stats_start_collector = true
#stats_reset_on_server_start = true
stats_command_string = true #false
stats_row_level = true# false
stats_block_level = true #false
Usage
./gentst.pl -m 512 | psql pgs | ./sumtst.pl  -b pgs
512 - is a RAM size of my notebook
Results

After eliminating of system cache (Linux), see gentst.pl for details I've got numbers compatible with Teodor's one: (Linux 2.4.20, 750Mhz, 512Mb, pgsql 7.3.4)

1048576+0 records in
1048576+0 records out
1048576+0 records in
1048576+0 records out
====Randomized table====
        Time: 342852 msec (500 queries)
        heap_blks       => 5883
        heap_blks_hit   => 14002        (238.01%)
        heap_blks_read  => 74983        (1274.57%)
        idx_blks        => 8564 
        idx_blks_hit    => 3798306      (44352.01%)
        idx_blks_read   => 142233       (1660.82%)
====Clustered table====
        Time: 56876 msec (500 queries)
        heap_blks       => 5883
        heap_blks_hit   => 84676        (1439.33%)
        heap_blks_read  => 2079         (35.34%)
        idx_blks        => 7665 
        idx_blks_hit    => 97412        (1270.87%)
        idx_blks_read   => 3898         (50.85%)