Re: Review/Pull Request: Adding new CRC32C implementation for IBM S390X

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Review/Pull Request: Adding new CRC32C implementation for IBM S390X
Дата
Msg-id 84824.1746657344@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Review/Pull Request: Adding new CRC32C implementation for IBM S390X  (John Naylor <johncnaylorls@gmail.com>)
Список pgsql-hackers
John Naylor <johncnaylorls@gmail.com> writes:
> We prefer that 'a' and 'b' are declared as global variables, just to
> make it as realistic as possible, although it doesn't seem to make
> much difference when I tried it on Compiler Explorer. (Same for
> autoconf)

Yeah, see commit fdb5dd6331e305f797bb589747f056062c305f0b for
some recent precedent, and for explanation of why we think it's
worth worrying about.  It's not so much that "global" matters,
it's that we don't want the compiler to have the option to
fold the whole test to a constant, which it would be within
its rights to do as you have this.

            regards, tom lane



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