Re: What is happening on buildfarm member dugong

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: What is happening on buildfarm member dugong
Дата
Msg-id 28406.1189522181@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: What is happening on buildfarm member dugong  ("Sergey E. Koposov" <math@sai.msu.ru>)
Список pgsql-hackers
"Sergey E. Koposov" <math@sai.msu.ru> writes:
>> BTW, does ICC have any switch corresponding to gcc's -fno-strict-aliasing?
>> I see that configure tries to feed that switch to it, but it might
>> want some other spelling.

> Apparently in none of the ICC manuals -fno-strict-aliasing is described, 
> but ICC accepts such flag, and produce the same code as with
> '-fno-alias' flag (described in ICC manuals).

Well, since configure.in has a separate code path for ICC anyway,
it seems like we might as well provide it the official spelling.
Any objections to a patch like this?
if test "$GCC" = yes -a "$ICC" = no; then  CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith -Winline"  #
Thesework in some but not all gcc versions  PGAC_PROG_CC_CFLAGS_OPT([-Wdeclaration-after-statement])
PGAC_PROG_CC_CFLAGS_OPT([-Wendif-labels]) # Disable strict-aliasing rules; needed for gcc 3.3+
PGAC_PROG_CC_CFLAGS_OPT([-fno-strict-aliasing])eliftest "$ICC" = yes; then  # Intel's compiler has a
bug/misoptimizationin checking for  # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
PGAC_PROG_CC_CFLAGS_OPT([-mp1])
-  # Not clear if this is needed, but seems like a good idea
-  PGAC_PROG_CC_CFLAGS_OPT([-fno-strict-aliasing])
+  # ICC prefers to spell the no-strict-aliasing switch like this
+  PGAC_PROG_CC_CFLAGS_OPT([-fno-alias])elif test x"${CC}" = x"xlc"; then  # AIX xlc has to have strict aliasing turned
offtoo  PGAC_PROG_CC_CFLAGS_OPT([-qnoansialias])fi
 
        regards, tom lane


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

Предыдущее
От: Simon Riggs
Дата:
Сообщение: Re: Final Thoughts for 8.3 on LWLocking and Scalability
Следующее
От: Zdenek Kotala
Дата:
Сообщение: Re: Per-function search_path => per-function GUC settings