Re: Bug in new buffer freelist code

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Bug in new buffer freelist code
Дата
Msg-id 28372.1072217014@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Bug in new buffer freelist code  (Jan Wieck <JanWieck@Yahoo.com>)
Ответы Re: Bug in new buffer freelist code  (Jan Wieck <JanWieck@Yahoo.com>)
Список pgsql-hackers
Jan Wieck <JanWieck@Yahoo.com> writes:
> It seems to me that buffers that are thrown away via 
> StrategyInvalidateBuffer() do not get their relnode and blocknum cleaned 
> out.

Mmmm.  They definitely should be; if you look at the prior version of
buf_table.c, BufTableDelete did this:
   /*    * Clear the buffer's tag.  This doesn't matter for the hash table,    * since the buffer is already removed
fromit, but it ensures that    * sequential searches through the buffer table won't think the buffer    * is still
validfor its old page.    */   buf->tag.rnode.relNode = InvalidOid;   buf->tag.rnode.tblNode = InvalidOid;
 

I see you removed that from the current version, but the equivalent
thing needs to be done someplace.  Is StrategyInvalidateBuffer the
right place?

BTW, it kinda looks like the BM_DELETED flag bit is useless now?
        regards, tom lane


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

Предыдущее
От: Jean-Michel POURE
Дата:
Сообщение: Re: PostgreSQL port to pure Java?
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Bug in new buffer freelist code