Re: testing HS/SR - 1 vs 2 performance

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: testing HS/SR - 1 vs 2 performance
Дата
Msg-id 2867.1272210617@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: testing HS/SR - 1 vs 2 performance  (Robert Haas <robertmhaas@gmail.com>)
Ответы Re: testing HS/SR - 1 vs 2 performance
Список pgsql-hackers
Robert Haas <robertmhaas@gmail.com> writes:
> On Sat, Apr 24, 2010 at 5:17 AM, Simon Riggs <simon@2ndquadrant.com> wrote:
> Both Heikki and I objected to that patch.
>> 
>> Please explain your objection, based upon the patch and my explanations.

> Well, we objected to the locking.

Not only is the locking overly complex, but it's outright wrong;
or at least the comments are.  KnownAssignedXidsAdd in particular
has a comment that is 100% misleading, and an actual behavior that
I find extremely likely to provoke bugs (eg, consider caller calling
it twice under the illusion it stlll has only shared lock).  I'm not
even convinced that it works correctly, since it will happily write
into KnownAssignedXids[] while holding only shared ProcArrayLock.
What happens when two processes are doing that concurrently?

This needs a redesign before it can be considered committable.  I don't
really care whether it makes things faster; it's too complicated and too
poorly documented to be maintainable.
        regards, tom lane


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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: testing HS/SR - 1 vs 2 performance
Следующее
От: Tom Lane
Дата:
Сообщение: Re: testing HS/SR - 1 vs 2 performance