Author: Paul Osmialowski Date: 2026-03-06T14:07:37Z New Revision: 57b0ff15880b3d5e798e07d76c3ed03289090cc8
URL: https://github.com/llvm/llvm-project/commit/57b0ff15880b3d5e798e07d76c3ed03289090cc8 DIFF: https://github.com/llvm/llvm-project/commit/57b0ff15880b3d5e798e07d76c3ed03289090cc8.diff LOG: [clang][test] Ensure the builtin_vectorelements.c test is actually executed (#184978) The REQUIRES statement in the builtin_vectorelements.c test case is an all-or-nothing declaration, hence all of the required conditions would need to be fulfilled to make this test being executed. Namely, all of those required targets whould have to be registered, which is a rare situstion, therefore this test case is rarely ever executed. This patch changes those REQUIRES statements into %if conditions. These conditions are needed for those particular targets as their test sections do include the header files available only when those targets are registered. Added: Modified: clang/test/CodeGen/builtin_vectorelements.c Removed: ################################################################################ diff --git a/clang/test/CodeGen/builtin_vectorelements.c b/clang/test/CodeGen/builtin_vectorelements.c index 45f7a3c34562b..5cbd68ba67cf9 100644 --- a/clang/test/CodeGen/builtin_vectorelements.c +++ b/clang/test/CodeGen/builtin_vectorelements.c @@ -1,13 +1,7 @@ -// RUN: %clang_cc1 -O1 -triple x86_64 %s -emit-llvm -disable-llvm-passes -o - | FileCheck --check-prefixes=CHECK %s - -// REQUIRES: aarch64-registered-target -// RUN: %clang_cc1 -O1 -triple aarch64 -target-feature +neon %s -emit-llvm -disable-llvm-passes -o - | FileCheck --check-prefixes=CHECK,NEON %s - -// REQUIRES: aarch64-registered-target -// RUN: %clang_cc1 -O1 -triple aarch64 -target-feature +sve %s -emit-llvm -disable-llvm-passes -o - | FileCheck --check-prefixes=CHECK,SVE %s - -// REQUIRES: riscv-registered-target -// RUN: %clang_cc1 -O1 -triple riscv64 -target-feature +v %s -emit-llvm -disable-llvm-passes -o - | FileCheck --check-prefixes=CHECK,RISCV %s +// RUN: %clang_cc1 -O1 -triple x86_64 %s -emit-llvm -disable-llvm-passes -o - | FileCheck --check-prefixes=CHECK %s +// RUN: %if aarch64-registered-target %{ %clang_cc1 -O1 -triple aarch64 -target-feature +neon %s -emit-llvm -disable-llvm-passes -o - | FileCheck --check-prefixes=CHECK,NEON %s %} +// RUN: %if aarch64-registered-target %{ %clang_cc1 -O1 -triple aarch64 -target-feature +sve %s -emit-llvm -disable-llvm-passes -o - | FileCheck --check-prefixes=CHECK,SVE %s %} +// RUN: %if riscv-registered-target %{ %clang_cc1 -O1 -triple riscv64 -target-feature +v %s -emit-llvm -disable-llvm-passes -o - | FileCheck --check-prefixes=CHECK,RISCV %s %} /// Note that this does not make sense to check for x86 SIMD types, because /// __m128i, __m256i, and __m512i do not specify the element type. There are no _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
