aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen
diff options
context:
space:
mode:
authorBrandon Wu <brandon.wu@sifive.com>2024-11-17 18:52:49 +0800
committerGitHub <noreply@github.com>2024-11-17 18:52:49 +0800
commit206ee7191834186ae78bf57fcf21d29dd7ce24cf (patch)
tree1cd64147445e2b74e81d951e0982c0f778e7acaa /llvm/lib/CodeGen
parent811186764d1add4d83972db3ad0d2e7c96bb15a7 (diff)
downloadllvm-206ee7191834186ae78bf57fcf21d29dd7ce24cf.zip
llvm-206ee7191834186ae78bf57fcf21d29dd7ce24cf.tar.gz
llvm-206ee7191834186ae78bf57fcf21d29dd7ce24cf.tar.bz2
[RISCV] Change vector tuple type's TypeSize to scalable (#114329)
Vector tuple is basically multiple grouped vector, so its size is also determined by vscale, we need not to model it as a vector type but its size need to be scalable.
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r--llvm/lib/CodeGen/ValueTypes.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/ValueTypes.cpp b/llvm/lib/CodeGen/ValueTypes.cpp
index e3c746b..2c80eee 100644
--- a/llvm/lib/CodeGen/ValueTypes.cpp
+++ b/llvm/lib/CodeGen/ValueTypes.cpp
@@ -163,7 +163,7 @@ std::string EVT::getEVTString() const {
switch (V.SimpleTy) {
default:
if (isRISCVVectorTuple()) {
- unsigned Sz = getSizeInBits();
+ unsigned Sz = getSizeInBits().getKnownMinValue();
unsigned NF = getRISCVVectorTupleNumFields();
unsigned MinNumElts = Sz / (NF * 8);
return "riscv_nxv" + utostr(MinNumElts) + "i8x" + utostr(NF);