From: Noah Misch <noah@leadboat.com>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Accept slightly-filled pages for tuples larger than fillfactor.
Date: Wed, 31 Mar 2021 01:55:03 +0000
Message-ID: <E1lRQ4V-0005Gj-Ou@gemulon.postgresql.org> (raw)
Accept slightly-filled pages for tuples larger than fillfactor.
We always inserted a larger-than-fillfactor tuple into a newly-extended
page, even when existing pages were empty or contained nothing but an
unused line pointer. This was unnecessary relation extension. Start
tolerating page usage up to 1/8 the maximum space that could be taken up
by line pointers. This is somewhat arbitrary, but it should allow more
cases to reuse pages. This has no effect on tables with fillfactor=100
(the default).
John Naylor and Floris van Nee. Reviewed by Matthias van de Meent.
Reported by Floris van Nee.
Discussion: https://postgr.es/m/6e263217180649339720afe2176c50aa@opammb0562.comp.optiver.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/0ff8bbdee19a9db2794a95d439c946ab017d0acd
Modified Files
--------------
src/backend/access/heap/hio.c | 43 +++++++++++++++++++++--------------
src/backend/access/heap/rewriteheap.c | 6 ++++-
src/test/regress/expected/insert.out | 21 +++++++++++++++++
src/test/regress/sql/insert.sql | 22 ++++++++++++++++++
4 files changed, 74 insertions(+), 18 deletions(-)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: noah@leadboat.com
Subject: Re: pgsql: Accept slightly-filled pages for tuples larger than fillfactor.
In-Reply-To: <E1lRQ4V-0005Gj-Ou@gemulon.postgresql.org>
References: <E1lRQ4V-0005Gj-Ou@gemulon.postgresql.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox