Re: Re: Uh, this is *not* a 64-bit CRC ...

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Re: Uh, this is *not* a 64-bit CRC ...
Дата
Msg-id 9432.983979247@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Uh, this is *not* a 64-bit CRC ...  ("Vadim Mikheev" <vmikheev@sectorbase.com>)
Список pgsql-hackers
"Vadim Mikheev" <vmikheev@sectorbase.com> writes:
> I've asked if anyone can send crc64 impl to me and got only one from
> Nathan Myers. Unfortunately, SWISS-PROT impl assumes that long long
> is 8 bytes - is it portable?

No, it's not.  I have written an implementation that uses uint64 if
available (per configure results) otherwise a pair of uint32 registers.
(See pg_crc.h in as-yet-uncommitted patches I posted to pgpatches.)

Interestingly, gcc -O on HP-PA generates essentially the same code
sequence for either the 64- or dual-32-bit versions of the macro...
        regards, tom lane


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

Предыдущее
От: Martin Devera
Дата:
Сообщение: Re: WAL & SHM principles
Следующее
От: Tom Lane
Дата:
Сообщение: Re: AW: AW: AW: AW: AW: WAL-based allocation of XIDs is ins ecur e