> >> What do you mean with using readahead inside the heapscan? 
> >> Starting an async read request?
> > 
> > Nope - just reading N buffers ahead for seqscans.  Subsequent calls 
> > use previously read pages.  The objective is to issue 
> contiguous reads 
> > to the OS in sizes greater than the PG page size (which is much 
> > smaller than what is needed for fast sequential I/O).
> Are you filling multiple buffers in the buffer cache with a 
> single read-call?

yes, needs vector or ScatterGather IO.
> The OS should be doing readahead for us 
> anyway, so I don't see how just issuing multiple ReadBuffers 
> one after each other helps.

Last time I looked OS readahead was only comparable to 32k blocked
256k blocked reads still perform way better. Also when the OS is
with an IO storm the 256k reads perform way better than OS readahead.


---------------------------(end of broadcast)---------------------------
TIP 7: You can help support the PostgreSQL project by donating at


Reply via email to