[clang] 4cd696f - [X86] Allow avx512vp2intersect to be used with __builtin_cpu_supports.

Craig Topper via cfe-commits cfe-commits at lists.llvm.org
Thu May 21 21:55:05 PDT 2020


Author: Craig Topper
Date: 2020-05-21T21:54:54-07:00
New Revision: 4cd696f92fde5fa0bc570ca059e0f1ce7344c807

URL: https://github.com/llvm/llvm-project/commit/4cd696f92fde5fa0bc570ca059e0f1ce7344c807
DIFF: https://github.com/llvm/llvm-project/commit/4cd696f92fde5fa0bc570ca059e0f1ce7344c807.diff

LOG: [X86] Allow avx512vp2intersect to be used with __builtin_cpu_supports.

compiler-rt and trunk libgcc support this now.

Added: 
    

Modified: 
    clang/test/CodeGen/target-builtin-noerror.c
    llvm/include/llvm/Support/X86TargetParser.def

Removed: 
    


################################################################################
diff  --git a/clang/test/CodeGen/target-builtin-noerror.c b/clang/test/CodeGen/target-builtin-noerror.c
index 37e9b50ddca4..54c5a9b7f218 100644
--- a/clang/test/CodeGen/target-builtin-noerror.c
+++ b/clang/test/CodeGen/target-builtin-noerror.c
@@ -81,6 +81,7 @@ void verifyfeaturestrings() {
   (void)__builtin_cpu_supports("avx512vnni");
   (void)__builtin_cpu_supports("avx512bitalg");
   (void)__builtin_cpu_supports("avx512bf16");
+  (void)__builtin_cpu_supports("avx512vp2intersect");
 }
 
 void verifycpustrings() {

diff  --git a/llvm/include/llvm/Support/X86TargetParser.def b/llvm/include/llvm/Support/X86TargetParser.def
index 4ebf2d79cb8d..f4780c7d113e 100644
--- a/llvm/include/llvm/Support/X86TargetParser.def
+++ b/llvm/include/llvm/Support/X86TargetParser.def
@@ -162,12 +162,12 @@ X86_FEATURE_COMPAT(33, FEATURE_VPCLMULQDQ,      "vpclmulqdq")
 X86_FEATURE_COMPAT(34, FEATURE_AVX512VNNI,      "avx512vnni")
 X86_FEATURE_COMPAT(35, FEATURE_AVX512BITALG,    "avx512bitalg")
 X86_FEATURE_COMPAT(36, FEATURE_AVX512BF16,      "avx512bf16")
+X86_FEATURE_COMPAT(69, FEATURE_AVX512VP2INTERSECT, "avx512vp2intersect")
 // Features below here are not in libgcc/compiler-rt.
 X86_FEATURE       (64, FEATURE_MOVBE)
 X86_FEATURE       (65, FEATURE_ADX)
 X86_FEATURE       (66, FEATURE_EM64T)
 X86_FEATURE       (67, FEATURE_CLFLUSHOPT)
 X86_FEATURE       (68, FEATURE_SHA)
-X86_FEATURE       (69, FEATURE_AVX512VP2INTERSECT)
 #undef X86_FEATURE_COMPAT
 #undef X86_FEATURE


        


More information about the cfe-commits mailing list