diff options
Diffstat (limited to 'llvm/lib/CodeGen/LowLevelType.cpp')
-rw-r--r-- | llvm/lib/CodeGen/LowLevelType.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/LowLevelType.cpp b/llvm/lib/CodeGen/LowLevelType.cpp index 40dfa696a2b9..33752a1f9230 100644 --- a/llvm/lib/CodeGen/LowLevelType.cpp +++ b/llvm/lib/CodeGen/LowLevelType.cpp @@ -19,7 +19,7 @@ using namespace llvm; LLT llvm::getLLTForType(Type &Ty, const DataLayout &DL) { if (auto VTy = dyn_cast<VectorType>(&Ty)) { - auto NumElements = VTy->getNumElements(); + auto NumElements = cast<FixedVectorType>(VTy)->getNumElements(); LLT ScalarTy = getLLTForType(*VTy->getElementType(), DL); if (NumElements == 1) return ScalarTy; |