Skip to content

Commit 8e01042

Browse files
authored
[RISCV] Add missing dependency check for Zvkb (#79467)
1 parent fd0637c commit 8e01042

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

clang/test/Driver/riscv-toolchain-gcc-multilib-reuse.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
// RUN: -target riscv64-unknown-elf \
6767
// RUN: --gcc-toolchain=%S/Inputs/multilib_riscv_elf_sdk \
6868
// RUN: --print-multi-directory \
69-
// RUN: -march=rv32i_zvkb -mabi=ilp32 \
69+
// RUN: -march=rv32iv_zvkb -mabi=ilp32 \
7070
// RUN: | FileCheck -check-prefix=GCC-MULTI-LIB-REUSE-RV32I_ZVKB-ILP32 %s
7171
// GCC-MULTI-LIB-REUSE-RV32I_ZVKB-ILP32: rv32i/ilp32
7272
// GCC-MULTI-LIB-REUSE-RV32I_ZVKB-ILP32-NOT: {{^.+$}}

llvm/lib/Support/RISCVISAInfo.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -976,8 +976,8 @@ Error RISCVISAInfo::checkDependency() {
976976
errc::invalid_argument,
977977
"'zvbc' requires 'v' or 'zve64*' extension to also be specified");
978978

979-
if ((Exts.count("zvkg") || Exts.count("zvkned") || Exts.count("zvknha") ||
980-
Exts.count("zvksed") || Exts.count("zvksh")) &&
979+
if ((Exts.count("zvkb") || Exts.count("zvkg") || Exts.count("zvkned") ||
980+
Exts.count("zvknha") || Exts.count("zvksed") || Exts.count("zvksh")) &&
981981
!HasVector)
982982
return createStringError(
983983
errc::invalid_argument,

0 commit comments

Comments
 (0)