[SVE] Remove calls to VectorType::getNumElements from FuzzMutate
authorChristopher Tetreault <ctetreau@quicinc.com>
Tue, 23 Jun 2020 17:48:08 +0000 (10:48 -0700)
committerChristopher Tetreault <ctetreau@quicinc.com>
Tue, 23 Jun 2020 18:02:20 +0000 (11:02 -0700)
Reviewers: efriedma, bkramer, kmclaughlin, sdesmalen

Reviewed By: sdesmalen

Subscribers: tschuett, hiraditya, rkruppe, psnobl, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D82212

llvm/lib/FuzzMutate/Operations.cpp

index d59b3cc..a37fd54 100644 (file)
@@ -302,7 +302,7 @@ static SourcePred validShuffleVectorIndex() {
     return ShuffleVectorInst::isValidOperands(Cur[0], Cur[1], V);
   };
   auto Make = [](ArrayRef<Value *> Cur, ArrayRef<Type *> Ts) {
-    auto *FirstTy = cast<VectorType>(Cur[0]->getType());
+    auto *FirstTy = cast<FixedVectorType>(Cur[0]->getType());
     auto *Int32Ty = Type::getInt32Ty(Cur[0]->getContext());
     // TODO: It's straighforward to make up reasonable values, but listing them
     // exhaustively would be insane. Come up with a couple of sensible ones.