Re: What exactly is our CRC algorithm?

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: What exactly is our CRC algorithm?
Дата
Msg-id CA+TgmoZFzPBY99xDSjFgow0aR_=wLmSjFPBVR6JngmdQwiy42A@mail.gmail.com
обсуждение исходный текст
Ответ на Re: What exactly is our CRC algorithm?  (Heikki Linnakangas <hlinnaka@iki.fi>)
Список pgsql-hackers
On Thu, Apr 2, 2015 at 5:33 PM, Heikki Linnakangas <hlinnaka@iki.fi> wrote:
> It was added in gcc 4.2. That's good enough for me.

I think it's fine to have optional optimizations that require gcc >=
4.2, as long as older platforms don't break outright.

>>> We have a buildfarm animal that still uses gcc 2.95.3, which was
>>> released in 2001. I don't have a compiler of that vintage to test
>>> with, but I assume an old enough assembler would not know about the
>>> crc32q instruction and fail to compile.
>>
>>
>> GCC from <2002 wouldn't support the symbolic operand names in inline
>> assembly. binutils from <2007 (IIRC) wouldn't support the assembler
>> instructions themselves.
>>
>> We could work around the latter by using the appropriate sequence of
>> bytes. We could work around the former by using the old syntax for
>> operands.
>
> I'm OK with not supporting the new instructions when building with an old
> compiler/assembler. But the build shouldn't fail with an old
> compiler/assembler. Using old syntax or raw bytes just to avoid failing on
> an ancient compiler seems ugly.

I dunno about old syntax, but raw bytes seems like a bad idea, for sure.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: Re: Abbreviated keys for Datum tuplesort
Следующее
От: Peter Geoghegan
Дата:
Сообщение: Re: Re: Abbreviated keys for Datum tuplesort