Re: Block-level CRC checks

Поиск
Список
Период
Сортировка
От Gregory Stark
Тема Re: Block-level CRC checks
Дата
Msg-id 87vdusu1bq.fsf@oxford.xeocode.com
обсуждение исходный текст
Ответ на Re: Block-level CRC checks  (Alvaro Herrera <alvherre@commandprompt.com>)
Ответы Re: Block-level CRC checks  (Alvaro Herrera <alvherre@commandprompt.com>)
Список pgsql-hackers
Alvaro Herrera <alvherre@commandprompt.com> writes:

> The other thing that maybe you didn't notice is that lp_flags are 2
> bits, not a full byte.  A byte-at-a-time CRC calculation is no help
> there.

I think we're talking past each other. Martin and I are talking about doing
something like:

for (...) ... crc(word including hint bits) ...
for (each line pointer) crc-negated(word & LP_DEAD<<15)
Because CRC is a cyclic checksum it's possible to add or remove bits
incrementally. This only works if the data is already copied to someplace so
you can be sure nobody will set or clear the bits behind your back. But when
you're reading the data back in you don't have to worry about that.

I'm a bit surprised to hear our CRC implementation is a bytewise loop. I
thought it was much faster to process CRC checks word-wise.

--  Gregory Stark EnterpriseDB          http://www.enterprisedb.com Ask me about EnterpriseDB's PostGIS support!


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Reducing some DDL Locks to ShareLock
Следующее
От: Ron Mayer
Дата:
Сообщение: Re: Re: Updated interval patches - ECPG [was, intervalstyle....]