[PATCH] D81500: [SVE] Remove calls to VectorType::getNumElements from IR

David Sherwood via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 23 08:31:33 PDT 2020


david-arm added inline comments.


================
Comment at: llvm/lib/IR/DataLayout.cpp:795
   if (VectorType *VecTy = dyn_cast<VectorType>(Ty))
-    return FixedVectorType::get(IntTy, VecTy->getNumElements());
+    return FixedVectorType::get(IntTy,
+                                cast<FixedVectorType>(VecTy)->getNumElements());
----------------
I already have a fix for this here that deals with scalable vectors and adds a test - https://reviews.llvm.org/D82294.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D81500/new/

https://reviews.llvm.org/D81500





More information about the llvm-commits mailing list