Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC - Mailing list pgsql-hackers

From Andres Freund
Subject Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC
Date
Msg-id 20170303225435.erbmcn6yn5b3itri@alap3.anarazel.de
Whole thread Raw
In response to [HACKERS] Skip all-visible pages during second HeapScan of CIC  (Pavan Deolasee <pavan.deolasee@gmail.com>)
Responses Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC  (Peter Geoghegan <pg@bowt.ie>)
Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC  (Stephen Frost <sfrost@snowman.net>)
List pgsql-hackers
Hi,

On 2017-02-28 19:12:03 +0530, Pavan Deolasee wrote:
> Since VM bits are only set during VACUUM which conflicts with CIC on the
> relation lock, I don't see any risk of incorrectly skipping pages that the
> second scan should have scanned.

I think that's true currently, but it'd also prevent us from doing that
in additional places.  Which, in my opinion, we really should (and I
believe that's realistically achievable).  Thus I really don't want to
base the correctness of CIC - a relatively infrequent operation - on the
assumption that no VM bits can be set concurrenty due to the SUE lock.

Regards,

Andres



pgsql-hackers by date:

Previous
From: Peter Geoghegan
Date:
Subject: Re: [HACKERS] GUC for cleanup indexes threshold.
Next
From: Peter Geoghegan
Date:
Subject: Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC