From: Heikki Linnakangas <hlinnaka@iki.fi>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-committers@postgresql.org
Subject: Re: pgsql: Fix handling of all-zero pages in SP-GiST vacuum.
Date: Mon, 27 Jul 2015 18:55:45 +0300
Message-ID: <55B65481.1040100@iki.fi> (raw)
In-Reply-To: <27183.1438011411@sss.pgh.pa.us>
References: <E1ZJk7X-0001dF-Bq@gemulon.postgresql.org>
<27183.1438011411@sss.pgh.pa.us>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>
On 07/27/2015 06:36 PM, Tom Lane wrote:
> Heikki Linnakangas <heikki.linnakangas@iki.fi> writes:
>> Fix handling of all-zero pages in SP-GiST vacuum.
>
> I'm a little bit uncomfortable with the way that this patch presumes that
> PageIsEmpty (a) is safe on an all-zeroes page and (b) will return true for
> such a page. Yes, it does work at the moment; but I don't think we are
> making such an assumption anyplace else, and in view of your other two
> concurrent patches, it doesn't seem very future-proof here either.
> I recommend that the code look more like
>
> if (!SpGistBlockIsRoot(blkno))
> {
> if (PageIsNew(page) || PageIsEmpty(page))
>
I thought I saw other places that assumed that, and I even thought I saw
a comment somewhere documenting that usage. But now that I grep around,
I see no such thing.
I'll go change that...
- Heikki
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
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: hlinnaka@iki.fi, tgl@sss.pgh.pa.us
Subject: Re: pgsql: Fix handling of all-zero pages in SP-GiST vacuum.
In-Reply-To: <55B65481.1040100@iki.fi>
References: <E1ZJk7X-0001dF-Bq@gemulon.postgresql.org> <27183.1438011411@sss.pgh.pa.us> <55B65481.1040100@iki.fi>
* 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