Re: condition variable cleanup and subtransactions

Поиск
Список
Период
Сортировка
От Thomas Munro
Тема Re: condition variable cleanup and subtransactions
Дата
Msg-id CAEepm=14vAPMUEhm5drRU=v+7C89wS2c9dvFyNQoN-b5gGXObA@mail.gmail.com
обсуждение исходный текст
Ответ на condition variable cleanup and subtransactions  (Andres Freund <andres@anarazel.de>)
Ответы Re: condition variable cleanup and subtransactions  (Robert Haas <robertmhaas@gmail.com>)
Re: condition variable cleanup and subtransactions  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
On Fri, Dec 22, 2017 at 12:00 AM, Andres Freund <andres@anarazel.de> wrote:
> Oh. This seems to be a condition variable bug independent of PHJ. The
> problem is that the DSM segment etc all get cleaned up in
> *subtransaction* abort.
>
> Afaict it's a bug that AbortTransaction() does
> ConditionVariableCancelSleep() but AbortSubTransaction() does not,
> despite the latter releasing dsm segments via
> ResourceOwnerRelease(RESOURCE_RELEASE_BEFORE_LOCKS).
>
> Adding that seems to fix the crash.
>
> This seems like something we need to backpatch.

Agreed.  That affects any user of condition variables inside DSM
segments, including the released Parallel Index Scan and Parallel
Bitmap Heap Scan code.

-- 
Thomas Munro
http://www.enterprisedb.com


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

Предыдущее
От: Ildar Musin
Дата:
Сообщение: Re: General purpose hashing func in pgbench
Следующее
От: Amit Kapila
Дата:
Сообщение: Re: [HACKERS] parallel.c oblivion of worker-startup failures