[LoongArch][Clang] Add tests for #110834 (#114509)
authorXi Ruoyao <xry111@xry111.site>
Sat, 2 Nov 2024 07:39:15 +0000 (15:39 +0800)
committerTobias Hieta <tobias@hieta.se>
Fri, 15 Nov 2024 08:21:06 +0000 (09:21 +0100)
(cherry picked from commit 96d2196f6f73e5712f1df8cd26de8a12c7f24de4)

clang/test/Headers/lasxintrin.c [new file with mode: 0644]
clang/test/Headers/lsxintrin.c [new file with mode: 0644]

diff --git a/clang/test/Headers/lasxintrin.c b/clang/test/Headers/lasxintrin.c
new file mode 100644 (file)
index 0000000..6126c63
--- /dev/null
@@ -0,0 +1,6 @@
+// RUN: %clang_cc1 %s -fsyntax-only -triple loongarch64 -target-feature +lasx
+// RUN: not %clang_cc1 %s -fsyntax-only -triple loongarch64 -target-feature +lasx -flax-vector-conversions=none
+// RUN: not %clang_cc1 %s -fsyntax-only -triple loongarch64 -target-feature +lasx -flax-vector-conversions=none -fno-signed-char
+// FIXME: "not" should be removed once we fix GH#110834.
+
+#include <lasxintrin.h>
diff --git a/clang/test/Headers/lsxintrin.c b/clang/test/Headers/lsxintrin.c
new file mode 100644 (file)
index 0000000..930d3ef
--- /dev/null
@@ -0,0 +1,6 @@
+// RUN: %clang_cc1 %s -fsyntax-only -triple loongarch64 -target-feature +lsx
+// RUN: not %clang_cc1 %s -fsyntax-only -triple loongarch64 -target-feature +lsx -flax-vector-conversions=none
+// RUN: not %clang_cc1 %s -fsyntax-only -triple loongarch64 -target-feature +lsx -flax-vector-conversions=none -fno-signed-char
+// FIXME: "not" should be removed once we fix GH#110834.
+
+#include <lsxintrin.h>