prefetch-explains.log

text/x-log

Filename: prefetch-explains.log
Type: text/x-log
Part: 1
Message: Re: index prefetching
INDEX_SCAN_MAX_BATCHES 64

                                                QUERY PLAN                                                
----------------------------------------------------------------------------------------------------------
 Aggregate (actual rows=1.00 loops=1)
   Buffers: shared read=191305
   ->  Limit (actual rows=10000000.00 loops=1)
         Buffers: shared read=191305
         ->  Index Scan using pgbench_accounts_pkey on pgbench_accounts (actual rows=10000000.00 loops=1)
               Index Searches: 1
               Prefetch Distance: 271.915
               Prefetch Stalls: 3
               Prefetch Resets: 3
               Buffers: shared read=191305
 Planning:
   Buffers: shared hit=46 read=22
 Planning Time: 3.996 ms
 Execution Time: 3593.458 ms
(14 rows)

                                                QUERY PLAN                                                
----------------------------------------------------------------------------------------------------------
 Aggregate (actual rows=1.00 loops=1)
   Buffers: shared read=191305
   ->  Limit (actual rows=10000000.00 loops=1)
         Buffers: shared read=191305
         ->  Index Scan using pgbench_accounts_pkey on pgbench_accounts (actual rows=10000000.00 loops=1)
               Index Searches: 1
               Prefetch Distance: 271.915
               Prefetch Stalls: 3
               Prefetch Resets: 3
               Buffers: shared read=191305
 Planning:
   Buffers: shared hit=61 read=25
 Planning Time: 4.211 ms
 Execution Time: 5163.463 ms
(14 rows)


INDEX_SCAN_MAX_BATCHES 32

                                                QUERY PLAN                                                
----------------------------------------------------------------------------------------------------------
 Aggregate (actual rows=1.00 loops=1)
   Buffers: shared read=191290
   ->  Limit (actual rows=10000000.00 loops=1)
         Buffers: shared read=191290
         ->  Index Scan using pgbench_accounts_pkey on pgbench_accounts (actual rows=10000000.00 loops=1)
               Index Searches: 1
               Prefetch Distance: 58.670
               Prefetch Stalls: 122939
               Prefetch Resets: 653
               Buffers: shared read=191290
 Planning:
   Buffers: shared hit=46 read=22
 Planning Time: 3.797 ms
 Execution Time: 3511.968 ms
(14 rows)

                                                QUERY PLAN                                                
----------------------------------------------------------------------------------------------------------
 Aggregate (actual rows=1.00 loops=1)
   Buffers: shared read=191290
   ->  Limit (actual rows=10000000.00 loops=1)
         Buffers: shared read=191290
         ->  Index Scan using pgbench_accounts_pkey on pgbench_accounts (actual rows=10000000.00 loops=1)
               Index Searches: 1
               Prefetch Distance: 58.670
               Prefetch Stalls: 122939
               Prefetch Resets: 653
               Buffers: shared read=191290
 Planning:
   Buffers: shared hit=61 read=25
 Planning Time: 4.108 ms
 Execution Time: 5150.282 ms
(14 rows)


INDEX_SCAN_MAX_BATCHES 16
                                                QUERY PLAN                                                
----------------------------------------------------------------------------------------------------------
 Aggregate (actual rows=1.00 loops=1)
   Buffers: shared read=191271
   ->  Limit (actual rows=10000000.00 loops=1)
         Buffers: shared read=191271
         ->  Index Scan using pgbench_accounts_pkey on pgbench_accounts (actual rows=10000000.00 loops=1)
               Index Searches: 1
               Prefetch Distance: 35.562
               Prefetch Stalls: 108101
               Prefetch Resets: 1190
               Buffers: shared read=191271
 Planning:
   Buffers: shared hit=46 read=22
 Planning Time: 3.965 ms
 Execution Time: 3568.817 ms
(14 rows)

                                                QUERY PLAN                                                
----------------------------------------------------------------------------------------------------------
 Aggregate (actual rows=1.00 loops=1)
   Buffers: shared read=191271
   ->  Limit (actual rows=10000000.00 loops=1)
         Buffers: shared read=191271
         ->  Index Scan using pgbench_accounts_pkey on pgbench_accounts (actual rows=10000000.00 loops=1)
               Index Searches: 1
               Prefetch Distance: 35.562
               Prefetch Stalls: 108101
               Prefetch Resets: 1190
               Buffers: shared read=191271
 Planning:
   Buffers: shared hit=61 read=25
 Planning Time: 4.371 ms
 Execution Time: 5108.845 ms
(14 rows)


INDEX_SCAN_MAX_BATCHES 8
                                                QUERY PLAN                                                
----------------------------------------------------------------------------------------------------------
 Aggregate (actual rows=1.00 loops=1)
   Buffers: shared read=191270
   ->  Limit (actual rows=10000000.00 loops=1)
         Buffers: shared read=191270
         ->  Index Scan using pgbench_accounts_pkey on pgbench_accounts (actual rows=10000000.00 loops=1)
               Index Searches: 1
               Prefetch Distance: 21.344
               Prefetch Stalls: 98775
               Prefetch Resets: 2104
               Buffers: shared read=191270
 Planning:
   Buffers: shared hit=46 read=22
 Planning Time: 3.706 ms
 Execution Time: 3646.034 ms
(14 rows)

                                                QUERY PLAN                                                
----------------------------------------------------------------------------------------------------------
 Aggregate (actual rows=1.00 loops=1)
   Buffers: shared read=191270
   ->  Limit (actual rows=10000000.00 loops=1)
         Buffers: shared read=191270
         ->  Index Scan using pgbench_accounts_pkey on pgbench_accounts (actual rows=10000000.00 loops=1)
               Index Searches: 1
               Prefetch Distance: 21.344
               Prefetch Stalls: 98775
               Prefetch Resets: 2104
               Buffers: shared read=191270
 Planning:
   Buffers: shared hit=61 read=25
 Planning Time: 4.280 ms
 Execution Time: 5198.426 ms
(14 rows)


INDEX_SCAN_MAX_BATCHES 4
                                                QUERY PLAN                                                
----------------------------------------------------------------------------------------------------------
 Aggregate (actual rows=1.00 loops=1)
   Buffers: shared read=191266
   ->  Limit (actual rows=10000000.00 loops=1)
         Buffers: shared read=191266
         ->  Index Scan using pgbench_accounts_pkey on pgbench_accounts (actual rows=10000000.00 loops=1)
               Index Searches: 1
               Prefetch Distance: 10.688
               Prefetch Stalls: 95627
               Prefetch Resets: 4556
               Buffers: shared read=191266
 Planning:
   Buffers: shared hit=46 read=22
 Planning Time: 3.799 ms
 Execution Time: 3784.910 ms
(14 rows)

                                                QUERY PLAN                                                
----------------------------------------------------------------------------------------------------------
 Aggregate (actual rows=1.00 loops=1)
   Buffers: shared read=191266
   ->  Limit (actual rows=10000000.00 loops=1)
         Buffers: shared read=191266
         ->  Index Scan using pgbench_accounts_pkey on pgbench_accounts (actual rows=10000000.00 loops=1)
               Index Searches: 1
               Prefetch Distance: 10.688
               Prefetch Stalls: 95627
               Prefetch Resets: 4556
               Buffers: shared read=191266
 Planning:
   Buffers: shared hit=61 read=25
 Planning Time: 4.330 ms
 Execution Time: 5195.308 ms
(14 rows)