Re: [HACKERS] Review: GIN non-intrusive vacuum of posting tree - Mailing list pgsql-hackers

From Andrew Borodin
Subject Re: [HACKERS] Review: GIN non-intrusive vacuum of posting tree
Date
Msg-id CAJEAwVGZP0iyt7=oDxbCh1OExa=7xmQ1PfkezXMxvz6cCTq8vQ@mail.gmail.com
Whole thread Raw
In response to Re: [HACKERS] Review: GIN non-intrusive vacuum of posting tree  (Teodor Sigaev <teodor@sigaev.ru>)
Responses Re: [HACKERS] Review: GIN non-intrusive vacuum of posting tree  (Teodor Sigaev <teodor@sigaev.ru>)
List pgsql-hackers
2017-03-22 22:48 GMT+05:00 Teodor Sigaev <teodor@sigaev.ru>:
> hasEmptyChild? and hasNonEmptyChild (BTW, isAnyNonempy has missed 't')

Yes, I think this naming is good. It's clear what's in common in these
flags and what's different.

> And if the whole posting tree is empty,then we could mark root page as leaf
> and remove all other pages in tree without any locking. Although, it could
> be a task for separate patch.

From the performance point of view, this is a very good idea. Both,
performance of VACUUM and performance of Scans. But doing so we risk
to leave some garbage pages in case of a crash. And I do not see how
to avoid these without unlinking pages one by one. I agree, that
leaving this trick for a separate patch is quite reasonable.

Best regards, Andrey Borodin.



pgsql-hackers by date:

Previous
From: Amit Kapila
Date:
Subject: Re: [HACKERS] Patch: Write Amplification Reduction Method (WARM)
Next
From: Andrew Gierth
Date:
Subject: Re: [HACKERS] Hash support for grouping sets