set effective_io_concurrency=0; set enable_indexscan=off; set enable_seqscan=off; explain (analyze, buffers)  select * from test where id between 90000 and 100000 and val != '';
                                                        QUERY PLAN                                                        
--------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on test  (cost=7.62..467.66 rows=498 width=36) (actual time=23.979..65.579 rows=10001 loops=1)
   Recheck Cond: ((id >= 90000) AND (id <= 100000))
   Filter: (val <> ''::text)
   Heap Blocks: exact=155
   Buffers: shared read=185
   ->  Bitmap Index Scan on test_pkey  (cost=0.00..7.49 rows=500 width=0) (actual time=23.217..23.217 rows=10001 loops=1)
         Index Cond: ((id >= 90000) AND (id <= 100000))
         Buffers: shared read=30
 Planning time: 50.628 ms
 Execution time: 66.322 ms
(10 rows)

set effective_io_concurrency=1; set enable_indexscan=off; set enable_seqscan=off; explain (analyze, buffers)  select * from test where id between 90000 and 100000 and val != '';
                                                        QUERY PLAN                                                        
--------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on test  (cost=7.62..467.66 rows=498 width=36) (actual time=11.090..442.494 rows=10001 loops=1)
   Recheck Cond: ((id >= 90000) AND (id <= 100000))
   Filter: (val <> ''::text)
   Heap Blocks: exact=155
   Buffers: shared read=185
   ->  Bitmap Index Scan on test_pkey  (cost=0.00..7.49 rows=500 width=0) (actual time=10.681..10.681 rows=10001 loops=1)
         Index Cond: ((id >= 90000) AND (id <= 100000))
         Buffers: shared read=30
 Planning time: 78.263 ms
 Execution time: 443.317 ms
(10 rows)

set effective_io_concurrency=0; set enable_indexscan=off; set enable_seqscan=off; explain (analyze, buffers)  select * from test where id between 90000 and 100000 and val != '';
                                                        QUERY PLAN                                                        
--------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on test  (cost=7.62..467.66 rows=498 width=36) (actual time=27.513..52.470 rows=10001 loops=1)
   Recheck Cond: ((id >= 90000) AND (id <= 100000))
   Filter: (val <> ''::text)
   Heap Blocks: exact=155
   Buffers: shared read=185
   ->  Bitmap Index Scan on test_pkey  (cost=0.00..7.49 rows=500 width=0) (actual time=26.763..26.763 rows=10001 loops=1)
         Index Cond: ((id >= 90000) AND (id <= 100000))
         Buffers: shared read=30
 Planning time: 62.643 ms
 Execution time: 53.138 ms
(10 rows)

set effective_io_concurrency=1; set enable_indexscan=off; set enable_seqscan=off; explain (analyze, buffers)  select * from test where id between 90000 and 100000 and val != '';
                                                        QUERY PLAN                                                        
--------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on test  (cost=7.62..467.66 rows=498 width=36) (actual time=16.501..566.051 rows=10001 loops=1)
   Recheck Cond: ((id >= 90000) AND (id <= 100000))
   Filter: (val <> ''::text)
   Heap Blocks: exact=155
   Buffers: shared read=185
   ->  Bitmap Index Scan on test_pkey  (cost=0.00..7.49 rows=500 width=0) (actual time=15.736..15.736 rows=10001 loops=1)
         Index Cond: ((id >= 90000) AND (id <= 100000))
         Buffers: shared read=30
 Planning time: 63.521 ms
 Execution time: 566.945 ms
(10 rows)

set effective_io_concurrency=0; set enable_indexscan=off; set enable_seqscan=off; explain (analyze, buffers)  select * from test where id between 90000 and 100000 and val != '';
                                                        QUERY PLAN                                                        
--------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on test  (cost=7.62..467.66 rows=498 width=36) (actual time=23.636..56.736 rows=10001 loops=1)
   Recheck Cond: ((id >= 90000) AND (id <= 100000))
   Filter: (val <> ''::text)
   Heap Blocks: exact=155
   Buffers: shared read=185
   ->  Bitmap Index Scan on test_pkey  (cost=0.00..7.49 rows=500 width=0) (actual time=23.225..23.225 rows=10001 loops=1)
         Index Cond: ((id >= 90000) AND (id <= 100000))
         Buffers: shared read=30
 Planning time: 49.492 ms
 Execution time: 57.441 ms
(10 rows)

set effective_io_concurrency=1; set enable_indexscan=off; set enable_seqscan=off; explain (analyze, buffers)  select * from test where id between 90000 and 100000 and val != '';
                                                        QUERY PLAN                                                        
--------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on test  (cost=7.62..467.66 rows=498 width=36) (actual time=25.489..524.919 rows=10001 loops=1)
   Recheck Cond: ((id >= 90000) AND (id <= 100000))
   Filter: (val <> ''::text)
   Heap Blocks: exact=155
   Buffers: shared read=185
   ->  Bitmap Index Scan on test_pkey  (cost=0.00..7.49 rows=500 width=0) (actual time=25.089..25.089 rows=10001 loops=1)
         Index Cond: ((id >= 90000) AND (id <= 100000))
         Buffers: shared read=30
 Planning time: 52.908 ms
 Execution time: 525.749 ms
(10 rows)

