Merge remote-tracking branch 'qatar/master'
authorMichael Niedermayer <michaelni@gmx.at>
Sat, 25 May 2013 19:42:56 +0000 (21:42 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Sat, 25 May 2013 19:43:13 +0000 (21:43 +0200)
* qatar/master:
  msvc/icl: Intel Compiler support on Windows

Conflicts:
configure

Merged-by: Michael Niedermayer <michaelni@gmx.at>
1  2 
configure

diff --cc configure
+++ b/configure
@@@ -2861,7 -2561,31 +2868,32 @@@ probe_cc()
          if [ $pfx = hostcc ]; then
              append _cflags -Dsnprintf=_snprintf
          fi
 +        disable stripping
+     elif $_cc 2>&1 | grep -q Intel; then
+         _type=icl
+         _ident=$($cc 2>&1 | head -n1)
+         _depflags='-QMMD -QMF$(@:.o=.d) -QMT$@'
+         # Not only is O3 broken on 13.x+ but it's slower on all previous versions (tested) as well
+         _cflags_speed="-O2"
+         _cflags_size="-O1 -Oi" # -O1 without -Oi miscompiles stuff
+         # Nonstandard output options, to avoid msys path conversion issues, relies on wrapper to remap it
+         if $_cc 2>&1 | grep -q Linker; then
+             _ld_o='-out $@'
+         else
+             _ld_o='-Fe$@'
+         fi
+         _cc_o='-Fo $@'
+         _cc_e='-P'
+         _flags_filter=msvc_flags
+         _ld_lib='lib%.a'
+         _ld_path='-libpath:'
+         # -Qdiag-error to make icl error when presented with certain unknown arguments
+         _flags='-nologo -Qdiag-error:10157 -Qdiag-error:4044'
+         # -Qvec- -Qsimd- to prevent miscompilation, -GS for consistency with msvc which enables it by default
+         _cflags='-D_USE_MATH_DEFINES -Dinline=__inline -FIstdlib.h -Dstrtoll=_strtoi64 -Qstd=c99 -Qms0 -Qvec- -Qsimd- -GS'
+         if [ $pfx = hostcc ]; then
+             append _cflags -Dsnprintf=_snprintf
+         fi
      fi
  
      eval ${pfx}_type=\$_type