aboutsummaryrefslogtreecommitdiff
path: root/gcc/config.gcc
diff options
context:
space:
mode:
authorH.J. Lu <hongjiu.lu@intel.com>2008-04-04 16:10:52 +0000
committerH.J. Lu <hjl@gcc.gnu.org>2008-04-04 09:10:52 -0700
commit8b96a312a0dbbfb84f5162a8a1cca553edac6fa8 (patch)
tree25211283997297a5a20cd8a102186f545171ee39 /gcc/config.gcc
parente892493899b225a21746d24221d7dc45fc19fed2 (diff)
downloadgcc-8b96a312a0dbbfb84f5162a8a1cca553edac6fa8.zip
gcc-8b96a312a0dbbfb84f5162a8a1cca553edac6fa8.tar.gz
gcc-8b96a312a0dbbfb84f5162a8a1cca553edac6fa8.tar.bz2
config.gcc (extra_headers): Add wmmintrin.h for x86 and x86-64.
gcc/ 2008-04-04 H.J. Lu <hongjiu.lu@intel.com> * config.gcc (extra_headers): Add wmmintrin.h for x86 and x86-64. * config/i386/cpuid.h (bit_AES): New. (bit_PCLMUL): Likewise. * config/i386/i386.c (pta_flags): Add PTA_AES and PTA_PCLMUL. (override_options): Handle PTA_AES and PTA_PCLMUL. Enable SSE2 if AES or PCLMUL is enabled. (ix86_builtins): Add IX86_BUILTIN_AESENC128, IX86_BUILTIN_AESENCLAST128, IX86_BUILTIN_AESDEC128, IX86_BUILTIN_AESDECLAST128, IX86_BUILTIN_AESIMC128, IX86_BUILTIN_AESKEYGENASSIST128 and IX86_BUILTIN_PCLMULQDQ128. (bdesc_sse_3arg): Add IX86_BUILTIN_PCLMULQDQ128. (bdesc_2arg): Add IX86_BUILTIN_AESENC128, IX86_BUILTIN_AESENCLAST128, IX86_BUILTIN_AESDEC128, IX86_BUILTIN_AESDECLAST128 and IX86_BUILTIN_AESKEYGENASSIST128. (bdesc_1arg): Add IX86_BUILTIN_AESIMC128. (ix86_init_mmx_sse_builtins): Define __builtin_ia32_aesenc128, __builtin_ia32_aesenclast128, __builtin_ia32_aesdec128, __builtin_ia32_aesdeclast128,__builtin_ia32_aesimc128, __builtin_ia32_aeskeygenassist128 and __builtin_ia32_pclmulqdq128. * config/i386/i386.c (ix86_expand_binop_imm_builtin): New. (ix86_expand_builtin): Use it for IX86_BUILTIN_PSLLDQI128 and IX86_BUILTIN_PSRLDQI128. Handle IX86_BUILTIN_AESKEYGENASSIST128. * config/i386/i386.h (TARGET_AES): New. (TARGET_PCLMUL): Likewise. (TARGET_CPU_CPP_BUILTINS): Handle TARGET_AES and TARGET_PCLMUL. * config/i386/i386.md (UNSPEC_AESENC): New. (UNSPEC_AESENCLAST): Likewise. (UNSPEC_AESDEC): Likewise. (UNSPEC_AESDECLAST): Likewise. (UNSPEC_AESIMC): Likewise. (UNSPEC_AESKEYGENASSIST): Likewise. (UNSPEC_PCLMULQDQ): Likewise. * config/i386/i386.opt (maes): New. (mpclmul): Likewise. * config/i386/sse.md (aesenc): New pattern. (aesenclast): Likewise. (aesdec): Likewise. (aesdeclast): Likewise. (aesimc): Likewise. (aeskeygenassist): Likewise. (pclmulqdq): Likewise. * config/i386/wmmintrin.h: New. * doc/extend.texi: Document AES and PCLMUL built-in function. * doc/invoke.texi: Document -maes and -mpclmul. gcc/testsuite/ 2008-04-04 H.J. Lu <hongjiu.lu@intel.com> * g++.dg/other/i386-2.C: Include <wmmintrin.h>. * g++.dg/other/i386-3.C: Likewise. * gcc.target/i386/sse-13.c: Likewise. * gcc.target/i386/sse-14.c: Likewise. * gcc.target/i386/aes-check.h: New. * gcc.target/i386/aesdec.c: Likewise. * gcc.target/i386/aesdeclast.c: Likewise. * gcc.target/i386/aesenc.c: Likewise. * gcc.target/i386/aesenclast.c: Likewise. * gcc.target/i386/aesimc.c: Likewise. * gcc.target/i386/aeskeygenassist.c: Likewise. * gcc.target/i386/pclmulqdq.c: Likewise. * gcc.target/i386/pclmul-check.h: Likewise. * gcc.target/i386/i386.exp (check_effective_target_aes): New. (check_effective_target_pclmul): Likewise. From-SVN: r133902
Diffstat (limited to 'gcc/config.gcc')
-rw-r--r--gcc/config.gcc6
1 files changed, 4 insertions, 2 deletions
diff --git a/gcc/config.gcc b/gcc/config.gcc
index 6c16e77..bc440c9 100644
--- a/gcc/config.gcc
+++ b/gcc/config.gcc
@@ -309,13 +309,15 @@ i[34567]86-*-*)
cpu_type=i386
extra_headers="cpuid.h mmintrin.h mm3dnow.h xmmintrin.h emmintrin.h
pmmintrin.h tmmintrin.h ammintrin.h smmintrin.h
- nmmintrin.h bmmintrin.h mmintrin-common.h"
+ nmmintrin.h bmmintrin.h mmintrin-common.h
+ wmmintrin.h"
;;
x86_64-*-*)
cpu_type=i386
extra_headers="cpuid.h mmintrin.h mm3dnow.h xmmintrin.h emmintrin.h
pmmintrin.h tmmintrin.h ammintrin.h smmintrin.h
- nmmintrin.h bmmintrin.h mmintrin-common.h"
+ nmmintrin.h bmmintrin.h mmintrin-common.h
+ wmmintrin.h"
need_64bit_hwint=yes
;;
ia64-*-*)