set effective_io_concurrency=0; set enable_indexscan=off; set enable_seqscan=off; explain (analyze, buffers)  select * from test where id between 65 and 100000 and val != '';
                                                        QUERY PLAN                                                        
--------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on test  (cost=7.62..467.66 rows=498 width=36) (actual time=83.995..840.711 rows=99936 loops=1)
   Recheck Cond: ((id >= 65) AND (id <= 100000))
   Filter: (val <> ''::text)
   Heap Blocks: exact=1539
   Buffers: shared read=1814
   ->  Bitmap Index Scan on test_pkey  (cost=0.00..7.49 rows=500 width=0) (actual time=82.668..82.668 rows=99936 loops=1)
         Index Cond: ((id >= 65) AND (id <= 100000))
         Buffers: shared read=275
 Planning time: 53.143 ms
 Execution time: 846.759 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 65 and 100000 and val != '';
                                                         QUERY PLAN                                                         
----------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on test  (cost=7.62..467.66 rows=498 width=36) (actual time=206.405..508.391 rows=99936 loops=1)
   Recheck Cond: ((id >= 65) AND (id <= 100000))
   Filter: (val <> ''::text)
   Heap Blocks: exact=1539
   Buffers: shared read=1814
   ->  Bitmap Index Scan on test_pkey  (cost=0.00..7.49 rows=500 width=0) (actual time=204.650..204.650 rows=99936 loops=1)
         Index Cond: ((id >= 65) AND (id <= 100000))
         Buffers: shared read=275
 Planning time: 65.062 ms
 Execution time: 514.668 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 65 and 100000 and val != '';
                                                        QUERY PLAN                                                        
--------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on test  (cost=7.62..467.66 rows=498 width=36) (actual time=80.790..530.645 rows=99936 loops=1)
   Recheck Cond: ((id >= 65) AND (id <= 100000))
   Filter: (val <> ''::text)
   Heap Blocks: exact=1539
   Buffers: shared read=1814
   ->  Bitmap Index Scan on test_pkey  (cost=0.00..7.49 rows=500 width=0) (actual time=79.484..79.484 rows=99936 loops=1)
         Index Cond: ((id >= 65) AND (id <= 100000))
         Buffers: shared read=275
 Planning time: 77.241 ms
 Execution time: 536.640 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 65 and 100000 and val != '';
                                                        QUERY PLAN                                                        
--------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on test  (cost=7.62..467.66 rows=498 width=36) (actual time=90.568..455.815 rows=99936 loops=1)
   Recheck Cond: ((id >= 65) AND (id <= 100000))
   Filter: (val <> ''::text)
   Heap Blocks: exact=1539
   Buffers: shared read=1814
   ->  Bitmap Index Scan on test_pkey  (cost=0.00..7.49 rows=500 width=0) (actual time=86.906..86.906 rows=99936 loops=1)
         Index Cond: ((id >= 65) AND (id <= 100000))
         Buffers: shared read=275
 Planning time: 61.820 ms
 Execution time: 461.966 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 65 and 100000 and val != '';
                                                         QUERY PLAN                                                         
----------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on test  (cost=7.62..467.66 rows=498 width=36) (actual time=214.030..1804.596 rows=99936 loops=1)
   Recheck Cond: ((id >= 65) AND (id <= 100000))
   Filter: (val <> ''::text)
   Heap Blocks: exact=1539
   Buffers: shared read=1814
   ->  Bitmap Index Scan on test_pkey  (cost=0.00..7.49 rows=500 width=0) (actual time=210.387..210.387 rows=99936 loops=1)
         Index Cond: ((id >= 65) AND (id <= 100000))
         Buffers: shared read=275
 Planning time: 63.798 ms
 Execution time: 1810.677 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 65 and 100000 and val != '';
                                                        QUERY PLAN                                                        
--------------------------------------------------------------------------------------------------------------------------
 Bitmap Heap Scan on test  (cost=7.62..467.66 rows=498 width=36) (actual time=77.211..539.280 rows=99936 loops=1)
   Recheck Cond: ((id >= 65) AND (id <= 100000))
   Filter: (val <> ''::text)
   Heap Blocks: exact=1539
   Buffers: shared read=1814
   ->  Bitmap Index Scan on test_pkey  (cost=0.00..7.49 rows=500 width=0) (actual time=73.581..73.581 rows=99936 loops=1)
         Index Cond: ((id >= 65) AND (id <= 100000))
         Buffers: shared read=275
 Planning time: 73.788 ms
 Execution time: 545.359 ms
(10 rows)

