On 01/11/2015 02:36 AM, Andres Freund wrote:
a) Afaics only __int128/unsigned __int128 is defined. See
    https://gcc.gnu.org/onlinedocs/gcc/_005f_005fint128.html

b) I'm doubtful that AC_CHECK_TYPES is a sufficiently good test on all
    platforms. IIRC gcc will generate calls to functions to do the actual
    arithmetic, and I don't think they're guranteed to be available on
    platforms. That how it .e.g. behaves for atomic operations. So my
    guess is that you'll need to check that a program that does actual
    arithmetic still links.

c) Personally I don't see the point of testing __uint128_t. That's just
    a pointless test that makes configure run for longer.

The next version will fix all these issues.

Hm. It might be nicer to move the if (!state) elog() outside the ifdef,
and add curly parens inside the ifdef.

Since that change only really works for the *_inv functions I decided to leave them all as-is for consistency.

--- a/src/include/pg_config.h.in
+++ b/src/include/pg_config.h.in
@@ -678,6 +678,12 @@
  /* Define to 1 if your compiler understands __VA_ARGS__ in macros. */
  #undef HAVE__VA_ARGS

z> +/* Define to 1 if the system has the type `__int128_t'. */
+#undef HAVE___INT128_T
+
+/* Define to 1 if the system has the type `__uint128_t'. */
+#undef HAVE___UINT128_T

pg_config.h.win32 should be updated as well.

Will be fixed in the next version.

--
Andreas Karlsson


--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to