Re: Streaming I/O, vectored I/O (WIP)

From: Thomas Munro <thomas(dot)munro(at)gmail(dot)com>
To: Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
Cc: Andres Freund <andres(at)anarazel(dot)de>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>, Melanie Plageman <melanieplageman(at)gmail(dot)com>
Subject: Re: Streaming I/O, vectored I/O (WIP)
Date: 2023-12-11 09:12:05
Message-ID: CA+hUKGK1GwoxONGftaP8M0git=Mo15oKytasY+ChV-2hF+726Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, Dec 9, 2023 at 10:23 PM Heikki Linnakangas <hlinnaka(at)iki(dot)fi> wrote:
> Ok, works for me.

I finished up making a few more improvements:

1. I eventually figured out how to generalise
compute_remaining_iovec() (as I now call it) so that the existing
pg_pwritev_with_retry() in file_utils.c could also use it, so that's
now done in a patch of its own.

2. FileReadV/FileWriteV patch:

* further simplification of the traditional ENOSPC 'guess'
* unconstify() changed to raw cast (pending [1])
* fixed the DO_DB()-wrapped debugging code

3. smgrreadv/smgrwritev patch:

* improved ENOSPC handling
* improve description of EOF and ENOSPC handling
* fixed the sizes reported in dtrace static probes
* fixed some words in the docs about that
* changed error messages to refer to "blocks %u..%u"

4. smgrprefetch-with-nblocks patch has no change, hasn't drawn any
comments hopefully because it is uncontroversial.

I'm planning to commit these fairly soon.

[1] https://www.postgresql.org/message-id/flat/CA%2BhUKGK3OXFjkOyZiw-DgL2bUqk9by1uGuCnViJX786W%2BfyDSw%40mail.gmail.com

Attachment Content-Type Size
v4-0001-Provide-helper-routine-for-partial-vector-I-O-ret.patch application/octet-stream 4.4 KB
v4-0002-Provide-vectored-variants-of-FileRead-and-FileWri.patch application/octet-stream 6.5 KB
v4-0003-Provide-vectored-variants-of-smgrread-and-smgrwri.patch application/octet-stream 21.5 KB
v4-0004-Provide-multi-block-smgrprefetch.patch application/octet-stream 6.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2023-12-11 09:17:51 Re: unconstify()/unvolatize() vs g++/clang++
Previous Message shveta malik 2023-12-11 09:11:26 Re: Synchronizing slots from primary to standby