heap_tuple_needs_freeze false positive

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема heap_tuple_needs_freeze false positive
Дата
Msg-id 1328144350-sup-771@alvh.no-ip.org
обсуждение исходный текст
Ответы Re: heap_tuple_needs_freeze false positive  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: heap_tuple_needs_freeze false positive  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
Hi,

I noticed that heap_tuple_needs_freeze might return true in cases where
the Xmax is leftover junk from somebody who set HEAP_XMAX_INVALID in the
far past without resetting the Xmax value itself to Invalid.  I think
this is incorrect usage; the rule, I think, is that one shouldn't even
read Xmax at all unless HEAP_XMAX_INVALID is reset.

This might cause unnecessary acquisitions of the cleanup lock, if a
tuple is deemed freezable when in fact it isn't.

Suggested patch attached.  I'd backpatch this as far as it applies
cleanly.

--
Álvaro Herrera <alvherre@alvh.no-ip.org>

Вложения

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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: foreign key locks, 2nd attempt
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: feature request - datum_compute_size and datum write_should be public