Prefetch cleanup: (#2876)

- **Enable `enable_seqscan_prefetch` by default**
- Drop use of `seqscan_prefetch_buffers` in favor of
`[maintenance,effective]_io_concurrency`
This includes adding some fields to the HeapScan execution node, and
vacuum state.
- Cleanup some conditionals in vacuumlazy.c
- Clarify enable_seqscan_prefetch GUC description
- Fix issues in heap SeqScan prefetching where synchronize_seqscan
machinery wasn't handled properly.
This commit is contained in:
MMeent
2022-12-02 13:35:01 +01:00
committed by GitHub
parent d90b52b405
commit 145e7e4b96
4 changed files with 10 additions and 9 deletions

View File

@@ -232,7 +232,8 @@ jobs:
if: matrix.platform == 'neon-captest-prefetch'
run: |
psql ${BENCHMARK_CONNSTR} -c "ALTER DATABASE neondb SET enable_seqscan_prefetch=on"
psql ${BENCHMARK_CONNSTR} -c "ALTER DATABASE neondb SET seqscan_prefetch_buffers=10"
psql ${BENCHMARK_CONNSTR} -c "ALTER DATABASE neondb SET effective_io_concurrency=32"
psql ${BENCHMARK_CONNSTR} -c "ALTER DATABASE neondb SET maintenance_io_concurrency=32"
env:
BENCHMARK_CONNSTR: ${{ steps.set-up-connstr.outputs.connstr }}

View File

@@ -464,12 +464,12 @@ pg_init_libpagestore(void)
NULL, NULL, NULL);
DefineCustomIntVariable("neon.readahead_buffer_size",
"number of prefetches to buffer",
"This buffer is used to store prefetched data; so "
"it is important that this buffer is at least as "
"large as the configured value of all tablespaces' "
"effective_io_concurrency and maintenance_io_concurrency, "
"your sessions' values of these, and the value for "
"seqscan_prefetch_buffers.",
"This buffer is used to hold and manage prefetched "
"data; so it is important that this buffer is at "
"least as large as the configured value of all "
"tablespaces' effective_io_concurrency and "
"maintenance_io_concurrency, and your sessions' "
"values for these settings.",
&readahead_buffer_size,
128, 16, 1024,
PGC_USERSET,