Re: GiST VACUUM - Mailing list pgsql-hackers

From Heikki Linnakangas
Subject Re: GiST VACUUM
Date
Msg-id 77c7023c-18d4-8f04-08ed-a5c5633046ea@iki.fi
Whole thread Raw
In response to Re: GiST VACUUM  (Andrey Borodin <x4mmm@yandex-team.ru>)
List pgsql-hackers
On 19/07/18 13:52, Andrey Borodin wrote:
> Hi!
> 
>> 19 июля 2018 г., в 1:12, Heikki Linnakangas <hlinnaka@iki.fi>
>> написал(а):
>> 
>> Yeah, please, I think this is the way to go.
> 
> Here's v11 divided into proposed steps.

Thanks, one quick question:

>             /* We should not unlock buffer if we are going to jump left */
>             if (needScan)
>             {
>                 GistBDItem *ptr = (GistBDItem *) palloc(sizeof(GistBDItem));
>                 ptr->buffer = buffer;
>                 ptr->next = bufferStack;
>                 bufferStack = ptr;
>             }
>             else
>                 UnlockReleaseBuffer(buffer);

Why? I don't see any need to keep the page locked, when we "jump left".

- Heikki


pgsql-hackers by date:

Previous
From: Andrey Borodin
Date:
Subject: Re: GiST VACUUM
Next
From: Pavel Stehule
Date:
Subject: Re: Runtime partition pruning for MergeAppend