[llvm] [llvm][SLPVectorizer] Fix a bad cast assertion (PR #97621)
Yingchi Long via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 3 16:25:48 PDT 2024
================
@@ -361,12 +361,14 @@ static bool isCommutative(Instruction *I) {
return I->isCommutative();
}
-/// \returns inserting index of InsertElement or InsertValue instruction,
-/// using Offset as base offset for index.
-static std::optional<unsigned> getInsertIndex(const Value *InsertInst,
- unsigned Offset = 0) {
+template <typename T>
+static std::optional<unsigned> getInsertExtractIndex(const Value *Inst,
----------------
inclyc wrote:
Yes I think you can commit this directly if you like, I don't have strong opinion about this.
https://github.com/llvm/llvm-project/pull/97621
More information about the llvm-commits
mailing list