Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 210622c

Browse filesBrowse files
committed
Provide vectored variant of ReadBuffer().
Break ReadBuffer() up into two steps. StartReadBuffers() and WaitReadBuffers() give us two main advantages: 1. Multiple consecutive blocks can be read with one system call. 2. Advice (hints of future reads) can optionally be issued to the kernel ahead of time. The traditional ReadBuffer() function is now implemented in terms of those functions, to avoid duplication. A new GUC io_combine_limit is defined, and the functions for limiting per-backend pin counts are made into public APIs. Those are provided for use by callers of StartReadBuffers(), when deciding how many buffers to read at once. The following commit will add a higher level mechanism for doing that automatically with a practical interface. With some more infrastructure in later work, StartReadBuffers() could be extended to start real asynchronous I/O instead of just issuing advice and leaving WaitReadBuffers() to do the work synchronously. Author: Thomas Munro <thomas.munro@gmail.com> Author: Andres Freund <andres@anarazel.de> (some optimization tweaks) Reviewed-by: Melanie Plageman <melanieplageman@gmail.com> Reviewed-by: Heikki Linnakangas <hlinnaka@iki.fi> Reviewed-by: Nazir Bilal Yavuz <byavuz81@gmail.com> Reviewed-by: Dilip Kumar <dilipbalaut@gmail.com> Reviewed-by: Andres Freund <andres@anarazel.de> Tested-by: Tomas Vondra <tomas.vondra@enterprisedb.com> Discussion: https://postgr.es/m/CA+hUKGJkOiOCa+mag4BF+zHo7qo=o9CFheB8=g6uT5TUm2gkvA@mail.gmail.com
1 parent 13b3b62 commit 210622c
Copy full SHA for 210622c

File tree

Expand file treeCollapse file tree

7 files changed

+605
-221
lines changed
Filter options
Expand file treeCollapse file tree

7 files changed

+605
-221
lines changed

‎doc/src/sgml/config.sgml

Copy file name to clipboardExpand all lines: doc/src/sgml/config.sgml
+14Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2708,6 +2708,20 @@ include_dir 'conf.d'
27082708
</listitem>
27092709
</varlistentry>
27102710

2711+
<varlistentry id="guc-io-combine-limit" xreflabel="io_combine_limit">
2712+
<term><varname>io_combine_limit</varname> (<type>integer</type>)
2713+
<indexterm>
2714+
<primary><varname>io_combine_limit</varname> configuration parameter</primary>
2715+
</indexterm>
2716+
</term>
2717+
<listitem>
2718+
<para>
2719+
Controls the largest I/O size in operations that combine I/O.
2720+
The default is 128kB.
2721+
</para>
2722+
</listitem>
2723+
</varlistentry>
2724+
27112725
<varlistentry id="guc-max-worker-processes" xreflabel="max_worker_processes">
27122726
<term><varname>max_worker_processes</varname> (<type>integer</type>)
27132727
<indexterm>

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.