[clang] 88c336d - [clang][Driver] Add more tests for riscv
Ben Shi via cfe-commits
cfe-commits at lists.llvm.org
Mon May 9 19:29:19 PDT 2022
Author: Ben Shi
Date: 2022-05-10T02:27:56Z
New Revision: 88c336d8eff03fc59a669c9ae4f2e415d95ff07c
URL: https://github.com/llvm/llvm-project/commit/88c336d8eff03fc59a669c9ae4f2e415d95ff07c
DIFF: https://github.com/llvm/llvm-project/commit/88c336d8eff03fc59a669c9ae4f2e415d95ff07c.diff
LOG: [clang][Driver] Add more tests for riscv
Reviewed By: benshi001
Differential Revision: https://reviews.llvm.org/D125157
Added:
Modified:
clang/test/Driver/riscv-arch.c
Removed:
################################################################################
diff --git a/clang/test/Driver/riscv-arch.c b/clang/test/Driver/riscv-arch.c
index 824e85eeb55fc..1a8c321e956be 100644
--- a/clang/test/Driver/riscv-arch.c
+++ b/clang/test/Driver/riscv-arch.c
@@ -559,3 +559,24 @@
// RUN: %clang --target=riscv32-unknown-elf -march=rv32ifdzve64d -### %s -c 2>&1 | \
// RUN: FileCheck -check-prefix=RV32-ZVE64D-GOOD %s
// RV32-ZVE64D-GOOD: "-target-feature" "+zve64d"
+
+// RUN: %clang --target=riscv32-unknown-elf -march=rv32izfinx -### %s \
+// RUN: -fsyntax-only 2>&1 | FileCheck -check-prefix=RV32-ZFINX-GOOD %s
+// RV32-ZFINX-GOOD: "-target-feature" "+zfinx"
+
+// RUN: %clang --target=riscv32-unknown-elf -march=rv32izdinx -### %s \
+// RUN: -fsyntax-only 2>&1 | FileCheck -check-prefix=RV32-ZDINX-GOOD %s
+// RV32-ZDINX-GOOD: "-target-feature" "+zdinx"
+
+// RUN: %clang --target=riscv32-unknown-elf -march=rv32izhinxmin -### %s \
+// RUN: -fsyntax-only 2>&1 | FileCheck -check-prefix=RV32-ZHINXMIN-GOOD %s
+// RV32-ZHINXMIN-GOOD: "-target-feature" "+zhinxmin"
+
+// RUN: %clang --target=riscv32-unknown-elf -march=rv32izhinx1p0 -### %s \
+// RUN: -fsyntax-only 2>&1 | FileCheck -check-prefix=RV32-ZHINX-GOOD %s
+// RV32-ZHINX-GOOD: "-target-feature" "+zhinx"
+
+// RUN: %clang --target=riscv32-unknown-elf -march=rv32izhinx0p1 -### %s \
+// RUN: -fsyntax-only 2>&1 | FileCheck -check-prefix=RV32-ZHINX-BADVERS %s
+// RV32-ZHINX-BADVERS: error: invalid arch name 'rv32izhinx0p1'
+// RV32-ZHINX-BADVERS: unsupported version number 0.1 for extension 'zhinx'
More information about the cfe-commits
mailing list