diff options
author | tocarip <tocarip@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-11-27 13:51:10 +0000 |
---|---|---|
committer | tocarip <tocarip@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-11-27 13:51:10 +0000 |
commit | ffbfc7c5d21f4014d6142b0a9db6d7fe2bde24df (patch) | |
tree | 385214d175b54af12c5051b97d93c7d7e00ebbd0 /libgcc | |
parent | ae22ef600294a0ac1ee90f10ca7354804b53a3ad (diff) | |
download | gcc-ffbfc7c5d21f4014d6142b0a9db6d7fe2bde24df.tar.gz |
Support avx512f in __builtin_cpu_supports.
gcc/
* config/i386/cpuid.h (bit_MPX, bit_BNDREGS, bit_BNDCSR):
Define.
* config/i386/i386.c (get_builtin_code_for_version): Add avx512f.
(fold_builtin_cpu): Ditto.
* doc/extend.texi: Documment it.
gcc/testsuite/
* g++.dg/ext/mv2.C: Add test for target ("avx512f").
* gcc.target/i386/builtin_target.c: Ditto.
libgcc/
* config/i386/cpuinfo.c (processor_features): Add FEATURE_AVX512F.
* config/i386/cpuinfo.c (get_available_features): Detect it.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@218125 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libgcc')
-rw-r--r-- | libgcc/ChangeLog | 5 | ||||
-rw-r--r-- | libgcc/config/i386/cpuinfo.c | 5 |
2 files changed, 9 insertions, 1 deletions
diff --git a/libgcc/ChangeLog b/libgcc/ChangeLog index ea3fdc87845..16114a7471e 100644 --- a/libgcc/ChangeLog +++ b/libgcc/ChangeLog @@ -1,3 +1,8 @@ +2014-11-27 Ilya Tocar <ilya.tocar@intel.com> + + * config/i386/cpuinfo.c (processor_features): Add FEATURE_AVX512F. + * config/i386/cpuinfo.c (get_available_features): Detect it. + 2014-11-27 Tony Wang <tony.wang@arm.com> * config/arm/lib1funcs.S (FUNC_START): Add conditional section diff --git a/libgcc/config/i386/cpuinfo.c b/libgcc/config/i386/cpuinfo.c index 6ff7502bb9a..8ca385cb977 100644 --- a/libgcc/config/i386/cpuinfo.c +++ b/libgcc/config/i386/cpuinfo.c @@ -96,7 +96,8 @@ enum processor_features FEATURE_SSE4_A, FEATURE_FMA4, FEATURE_XOP, - FEATURE_FMA + FEATURE_FMA, + FEATURE_AVX512F }; struct __processor_model @@ -278,6 +279,8 @@ get_available_features (unsigned int ecx, unsigned int edx, __cpuid_count (7, 0, eax, ebx, ecx, edx); if (ebx & bit_AVX2) features |= (1 << FEATURE_AVX2); + if (ebx & bit_AVX512F) + features |= (1 << FEATURE_AVX512F); } unsigned int ext_level; |