[PATCH] D102615: [LoopDeletion] Break backedge if we can prove that the loop is exited on 1st iteration (try 3)
Max Kazantsev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 17 02:50:09 PDT 2021
mkazantsev added a comment.
> This is surprising to me -- why does this require changes to InstSimplify?
InstSimplify does not provide public API for this:
const SCEV *LHSS = getSCEVOnFirstIteration(LHS, L, SE, FirstIterSCEV);
const SCEV *RHSS = getSCEVOnFirstIteration(RHS, L, SE, FirstIterSCEV);
S = SE.getAddExpr(LHSS, RHSS);
It has `SimplifyAddInst` that works with custom arguments, but it's currently static within the cpp file. I'd need to expose all of them. At least this, maybe more.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D102615/new/
https://reviews.llvm.org/D102615
More information about the llvm-commits
mailing list