Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC

Поиск
Список
Период
Сортировка
От Stephen Frost
Тема Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC
Дата
Msg-id 20170303230651.GW9812@tamriel.snowman.net
обсуждение исходный текст
Ответ на Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC  (Andres Freund <andres@anarazel.de>)
Ответы Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
Andres,

* Andres Freund (andres@anarazel.de) wrote:
> 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.

That sounds like we need a lock or similar mechanism to indicate that
CIC depends on the VM not being changed, rather than saying it shouldn't
depend on that because it might not always be true that the only other
operation (VACUUM) sets them and already acquires a conflicting lock.

Thanks!

Stephen

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Peter Geoghegan
Дата:
Сообщение: Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC
Следующее
От: Peter Geoghegan
Дата:
Сообщение: Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC