[llvm] [NFC] Add assertions for Src and Dst vec types in VecCombine folding (PR #134432)
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Sun Apr 6 05:31:15 PDT 2025
================
@@ -2052,6 +2052,9 @@ bool VectorCombine::foldShuffleOfSelects(Instruction &I) {
auto *SrcVecTy = dyn_cast<FixedVectorType>(T1->getType());
auto *DstVecTy = dyn_cast<FixedVectorType>(I.getType());
+ assert(SrcVecTy && DstVecTy &&
----------------
RKSimon wrote:
yes - replace those 2 dyn_cast with cast - the previous dyn_cast checks for the select condition operands should be ensuring FixedVectorType for everything
https://github.com/llvm/llvm-project/pull/134432
More information about the llvm-commits
mailing list