Re: pgsql: dshash: Add sequential scan support.

Поиск
Список
Период
Сортировка
От Thomas Munro
Тема Re: pgsql: dshash: Add sequential scan support.
Дата
Msg-id CA+hUKGK=YDaxXanxSpMOKZxzAEUq9RGtcfY7sZTZO-WpLBFJEQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: pgsql: dshash: Add sequential scan support.  (Andres Freund <andres@anarazel.de>)
Ответы Re: pgsql: dshash: Add sequential scan support.  (Thomas Munro <thomas.munro@gmail.com>)
Список pgsql-hackers
On Tue, Jul 5, 2022 at 11:25 AM Andres Freund <andres@anarazel.de> wrote:
> On 2022-07-05 11:20:54 +1200, Thomas Munro wrote:
> > Since there were 6 places with I-hold-no-lock assertions, I shoved the
> > loop into a function so I could do:
> >
> > -               Assert(!status->hash_table->find_locked);
> > +               assert_no_lock_held_by_me(hash_table);
>
> I am a *bit* wary about the costs of that, even in assert builds - each of the
> partition checks in the loop will in turn need to iterate through
> held_lwlocks. But I guess we can also just later weaken them if it turns out
> to be a problem.

Maybe we should add assertion support for arrays of locks, so we don't
need two levels of loop?  Something like the attached?

Вложения

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

Предыдущее
От: Ibrar Ahmed
Дата:
Сообщение: CFM Manager
Следующее
От: Masahiko Sawada
Дата:
Сообщение: Re: [PoC] Improve dead tuple storage for lazy vacuum