Re: Sequential disk access during VACUUM for GiST/GIN

Lists: pgsql-hackers
From: Костя Кузнецов <chapaev28(at)yandex(dot)ru>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Sequential disk access during VACUUM for GiST/GIN
Date: 2014-04-29 10:34:22
Message-ID: 13731398767662@web11g.yandex.ru
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

<div>Hello.</div><div>There is a task "Sequential disk access during VACUUM for GiST/GIN " in list GSOC14.</div><div>Nobody is working on this task?</div><div><span lang="en"><span>Do I understand</span> <span>this task correctly</span><span>?</span></span></div><div><span lang="en"><span>I must recode gistbulkdelete.</span></span></div><div><span lang="en"><span>GistBDItem *stack is must have items with sequential blkno as possible.</span></span></div><div><span lang="en"><span>I have a question:</span></span></div><div><span lang="en"><span>where are access to disk in this function? ReadBufferExtended?</span></span></div><div><span lang="en"><span>Thanks</span></span></div>

Attachment Content-Type Size
unknown_filename text/html 687 bytes

From: Alexander Korotkov <aekorotkov(at)gmail(dot)com>
To: Костя Кузнецов <chapaev28(at)yandex(dot)ru>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Sequential disk access during VACUUM for GiST/GIN
Date: 2014-05-06 10:46:55
Message-ID: CAPpHfdsKWm1AbHqEs3n3s2GVHGQ4+H3ZR7KpDFG=EvqX_hsQTg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Hi!

On Tue, Apr 29, 2014 at 2:34 PM, Костя Кузнецов <chapaev28(at)yandex(dot)ru> wrote:

> There is a task "Sequential disk access during VACUUM for GiST/GIN " in
> list GSOC14.
> Nobody is working on this task?
>

I didn't hear anybody is working on it.

> Do I understand this task correctly?
> I must recode gistbulkdelete.
> GistBDItem *stack is must have items with sequential blkno as possible.
>

Yes, make gistbulkdelete and ginbulkdelete access disk sequentially while
now tree is traversed in logical order. So these functions need to be
completely reworked: I'm not sure GistBDItem will survive :)
The challenge is concurrency. Vacuum shouldn't block concurrent readers and
writers. You can see btbulkdelete which supports sequential disk access
now.

> I have a question:
> where are access to disk in this function? ReadBufferExtended?
>

Yes, this function read buffer to shared memory (if it isn't already) and
"pins" it.

------
With best regards,
Alexander Korotkov.