[PATCH] D78967: [SVE] Remove invalid usage of VectorType::getNumElements in Function
Christopher Tetreault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 28 13:29:33 PDT 2020
This revision was automatically updated to reflect the committed changes.
Closed by commit rG2e214baed929: [SVE] Remove invalid usage of VectorType::getNumElements in Function (authored by ctetreau).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D78967/new/
https://reviews.llvm.org/D78967
Files:
llvm/lib/IR/Function.cpp
Index: llvm/lib/IR/Function.cpp
===================================================================
--- llvm/lib/IR/Function.cpp
+++ llvm/lib/IR/Function.cpp
@@ -1074,8 +1074,8 @@
// Return the overloaded type (which determines the pointers address space)
return Tys[D.getOverloadArgNumber()];
case IITDescriptor::ScalableVecArgument: {
- auto *Ty = cast<VectorType>(DecodeFixedType(Infos, Tys, Context));
- return VectorType::get(Ty->getElementType(), {Ty->getNumElements(), true});
+ auto *Ty = cast<FixedVectorType>(DecodeFixedType(Infos, Tys, Context));
+ return ScalableVectorType::get(Ty->getElementType(), Ty->getNumElements());
}
}
llvm_unreachable("unhandled");
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D78967.260747.patch
Type: text/x-patch
Size: 705 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200428/3e53fbc3/attachment.bin>
More information about the llvm-commits
mailing list