Re: Seq scans roadmap

Поиск
Список
Период
Сортировка
От Zeugswetter Andreas ADI SD
Тема Re: Seq scans roadmap
Дата
Msg-id E1539E0ED7043848906A8FF995BDA57901FD9725@m0143.s-mxs.net
обсуждение исходный текст
Ответ на Re: Seq scans roadmap  ("Luke Lonergan" <LLonergan@greenplum.com>)
Список pgsql-hackers
> 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).

Problem here is that eighter you issue the large read into throwaway
private memory and hope that when you later read 8k you get the page
from OS buffercache, or you need ScatterGather IO and a way to grab 32
buffers at once.

> Yes, I think the ring buffer strategy should be used when the
> table size is > 1 x bufcache and the ring buffer should be of
> a fixed size smaller than L2 cache (32KB - 128KB seems to work well).

How do you merge those two objectives? It seems the ring buffer needs to
be at least as large as the contiguous read size.
Thus you would need at least 256k ring buffer. Better yet have twice the
IO size as ring buffer size, so two sessions can alternately take the
lead while the other session still blocks a prev page. Modern L2 cache
is 8 Mb, so 512k seems no problem ?

Andreas


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: [COMMITTERS] psqlodbc - psqlodbc: Put Autotools-generated files into subdirectory
Следующее
От: "Zeugswetter Andreas ADI SD"
Дата:
Сообщение: Re: Seq scans roadmap