[llvm] [LV] Remove common extends and selects in CSE (PR #147731)
Sander de Smalen via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 10 03:34:59 PDT 2025
================
@@ -804,6 +804,10 @@ int FunctionComparator::cmpOperations(const Instruction *L,
return Res;
}
}
+ if (const CastInst *Cast = dyn_cast<CastInst>(L)) {
+ const CastInst *CastR = cast<CastInst>(R);
+ return cmpTypes(Cast->getDestTy(), CastR->getDestTy());
----------------
sdesmalen-arm wrote:
@SamTebbs33 do we need a separate test for the FunctionComparator change? (I don't think that's currently tested?)
https://github.com/llvm/llvm-project/pull/147731
More information about the llvm-commits
mailing list