aboutsummaryrefslogtreecommitdiff
path: root/gcc/common/config
diff options
context:
space:
mode:
authorAlexander Ivchenko <alexander.ivchenko@intel.com>2014-08-11 11:22:26 +0000
committerKirill Yukhin <kyukhin@gcc.gnu.org>2014-08-11 11:22:26 +0000
commitb525d9437ff21d934cd930de661b0e6891b49c2c (patch)
tree364f4c0d8e9c8083588618f90b24c9d000f59643 /gcc/common/config
parent5f732aeb8ebbe04e9912faa497093dd91e8dc898 (diff)
downloadgcc-b525d9437ff21d934cd930de661b0e6891b49c2c.zip
gcc-b525d9437ff21d934cd930de661b0e6891b49c2c.tar.gz
gcc-b525d9437ff21d934cd930de661b0e6891b49c2c.tar.bz2
i386-common.c (OPTION_MASK_ISA_AVX512BW_SET): Define.
gcc/ * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512BW_SET) : Define. (OPTION_MASK_ISA_AVX512BW_UNSET): Ditto. (OPTION_MASK_ISA_AVX512VL_UNSET) : Ditto. (ix86_handle_option): Handle OPT_mavx512bw. * config/i386/cpuid.h (bit_AVX512BW): Define. * config/i386/driver-i386.c (host_detect_local_cpu): Detect avx512bw, set -mavx512bw accordingly. * config/i386/i386-c.c (ix86_target_macros_internal): Handle OPTION_MASK_ISA_AVX512BW. * config/i386/i386.c (ix86_target_string): Handle -mavx512bw. (ix86_option_override_internal): Define PTA_AVX512BW, handle PTA_AVX512BW and OPTION_MASK_ISA_AVX512BW. (ix86_valid_target_attribute_inner_p): Handle OPT_mavx512bw. * config/i386/i386.h (TARGET_AVX512BW): Define. (TARGET_AVX512BW_P(x)): Ditto. * config/i386/i386.opt: Add mavx512bw. Co-Authored-By: Andrey Turetskiy <andrey.turetskiy@intel.com> Co-Authored-By: Anna Tikhonova <anna.tikhonova@intel.com> Co-Authored-By: Ilya Tocar <ilya.tocar@intel.com> Co-Authored-By: Ilya Verbin <ilya.verbin@intel.com> Co-Authored-By: Kirill Yukhin <kirill.yukhin@intel.com> Co-Authored-By: Maxim Kuznetsov <maxim.kuznetsov@intel.com> Co-Authored-By: Michael Zolotukhin <michael.v.zolotukhin@intel.com> From-SVN: r213811
Diffstat (limited to 'gcc/common/config')
-rw-r--r--gcc/common/config/i386/i386-common.c19
1 files changed, 18 insertions, 1 deletions
diff --git a/gcc/common/config/i386/i386-common.c b/gcc/common/config/i386/i386-common.c
index 3db1535..bb7bc46 100644
--- a/gcc/common/config/i386/i386-common.c
+++ b/gcc/common/config/i386/i386-common.c
@@ -67,6 +67,8 @@ along with GCC; see the file COPYING3. If not see
(OPTION_MASK_ISA_AVX512ER | OPTION_MASK_ISA_AVX512F_SET)
#define OPTION_MASK_ISA_AVX512DQ_SET \
(OPTION_MASK_ISA_AVX512DQ | OPTION_MASK_ISA_AVX512F_SET)
+#define OPTION_MASK_ISA_AVX512BW_SET \
+ (OPTION_MASK_ISA_AVX512BW | OPTION_MASK_ISA_AVX512F_SET)
#define OPTION_MASK_ISA_RTM_SET OPTION_MASK_ISA_RTM
#define OPTION_MASK_ISA_PRFCHW_SET OPTION_MASK_ISA_PRFCHW
#define OPTION_MASK_ISA_RDSEED_SET OPTION_MASK_ISA_RDSEED
@@ -154,11 +156,13 @@ along with GCC; see the file COPYING3. If not see
(OPTION_MASK_ISA_AVX2 | OPTION_MASK_ISA_AVX512F_UNSET)
#define OPTION_MASK_ISA_AVX512F_UNSET \
(OPTION_MASK_ISA_AVX512F | OPTION_MASK_ISA_AVX512CD_UNSET \
- | OPTION_MASK_ISA_AVX512PF_UNSET | OPTION_MASK_ISA_AVX512ER_UNSET)
+ | OPTION_MASK_ISA_AVX512PF_UNSET | OPTION_MASK_ISA_AVX512ER_UNSET \
+ | OPTION_MASK_ISA_AVX512DQ_UNSET | OPTION_MASK_ISA_AVX512BW_UNSET)
#define OPTION_MASK_ISA_AVX512CD_UNSET OPTION_MASK_ISA_AVX512CD
#define OPTION_MASK_ISA_AVX512PF_UNSET OPTION_MASK_ISA_AVX512PF
#define OPTION_MASK_ISA_AVX512ER_UNSET OPTION_MASK_ISA_AVX512ER
#define OPTION_MASK_ISA_AVX512DQ_UNSET OPTION_MASK_ISA_AVX512DQ
+#define OPTION_MASK_ISA_AVX512BW_UNSET OPTION_MASK_ISA_AVX512BW
#define OPTION_MASK_ISA_RTM_UNSET OPTION_MASK_ISA_RTM
#define OPTION_MASK_ISA_PRFCHW_UNSET OPTION_MASK_ISA_PRFCHW
#define OPTION_MASK_ISA_RDSEED_UNSET OPTION_MASK_ISA_RDSEED
@@ -409,6 +413,19 @@ ix86_handle_option (struct gcc_options *opts,
}
return true;
+ case OPT_mavx512bw:
+ if (value)
+ {
+ opts->x_ix86_isa_flags |= OPTION_MASK_ISA_AVX512BW_SET;
+ opts->x_ix86_isa_flags_explicit |= OPTION_MASK_ISA_AVX512BW_SET;
+ }
+ else
+ {
+ opts->x_ix86_isa_flags &= ~OPTION_MASK_ISA_AVX512BW_UNSET;
+ opts->x_ix86_isa_flags_explicit |= OPTION_MASK_ISA_AVX512BW_UNSET;
+ }
+ return true;
+
case OPT_mfma:
if (value)
{