03-14-2011 02:51 PM
I am compiling a Python/Cython/C project with Intel's compiler, and I need to find an icc option that is _exactly_ equivalent to gcc's -fno-strict-aliasing flag. It appears that icc accepts -fno-strict-aliasing directly, but this behavior is not documented in the "Portability Options" section of the manual, so I am not sure whether the flag is simply being silently ignored. It appears that icc's -no-ansi-alias flag is related to gcc's -fno-strict-aliasing flag, but I would like definitive confirmation either that icc correctly accepts -fno-strict aliasing or that -no-ansi-alias is an exact substitute. Thanks.
03-15-2011 07:16 AM
icc default option -no-ansi-alias is equivalent to gcc -no-strict-aliasing. Remember that an application which depends on this is in violation of C and C++ standards and many optimizations will be disabled.