public inbox for [email protected]  
help / color / mirror / Atom feed
From: Tom Lane <[email protected]>
To: John Naylor <[email protected]>
Cc: Eduard Stefes <[email protected]>
Cc: [email protected] <[email protected]>
Cc: [email protected] <[email protected]>
Cc: [email protected] <[email protected]>
Subject: Re: Review/Pull Request: Adding new CRC32C implementation for IBM S390X
Date: Wed, 07 May 2025 18:35:44 -0400
Message-ID: <[email protected]> (raw)
In-Reply-To: <CANWCAZbPffcCcLCBU8BkQChK7AV1dhvAgJgpjiF9aSgHuppr5Q@mail.gmail.com>
References: <[email protected]>
	<CANWCAZbPffcCcLCBU8BkQChK7AV1dhvAgJgpjiF9aSgHuppr5Q@mail.gmail.com>

John Naylor <[email protected]> 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





view thread (9+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: Re: Review/Pull Request: Adding new CRC32C implementation for IBM S390X
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox