Skip to content

Commit 2abaaf6

Browse files
committed
fixup! [RISCV] Change vector tuple type's TypeSize to scalable
1 parent b002911 commit 2abaaf6

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

llvm/include/llvm/CodeGen/ValueTypes.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,8 @@ namespace llvm {
185185

186186
/// Return true if the type is a scalable type.
187187
bool isScalableVT() const {
188-
return isScalableVector() || isScalableTargetExtVT();
188+
return isScalableVector() || isScalableTargetExtVT() ||
189+
isRISCVVectorTuple();
189190
}
190191

191192
/// Return true if this is a 16-bit vector type.

llvm/include/llvm/CodeGen/ValueTypes.td

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@ class VTVecTup<int size, int nf, ValueType dummy_elt, int value>
6363
let NF = nf;
6464
let ElementType = dummy_elt;
6565
let isRISCVVecTuple = true;
66-
let isScalable = true;
6766
}
6867

6968
defset list<ValueType> ValueTypes = {

llvm/include/llvm/CodeGenTypes/MachineValueType.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,12 +306,14 @@ namespace llvm {
306306
/// be set and the runtime size will be a positive integer multiple of the
307307
/// base size.
308308
TypeSize getSizeInBits() const {
309+
// clang-format off
309310
static constexpr TypeSize SizeTable[] = {
310311
#define GET_VT_ATTR(Ty, N, Sz, Any, Int, FP, Vec, Sc, Tup, NF, NElem, EltTy) \
311-
TypeSize(Sz, Sc || Ty == aarch64svcount /* FIXME: Not in the td. */),
312+
TypeSize(Sz, Sc || Tup || Ty == aarch64svcount /* FIXME: Not in the td. */),
312313
#include "llvm/CodeGen/GenVT.inc"
313314
#undef GET_VT_ATTR
314315
};
316+
// clang-format on
315317

316318
switch (SimpleTy) {
317319
case INVALID_SIMPLE_VALUE_TYPE:

0 commit comments

Comments
 (0)