mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-08 06:32:24 +00:00
Cleanup comments and argument types related to my previous replaceCongruentPhis checkin.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@147709 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
b78307fc58
commit
139f333f88
@ -1558,8 +1558,8 @@ bool SCEVExpander::hoistStep(Instruction *IncV, Instruction *InsertPos,
|
||||
return true;
|
||||
}
|
||||
|
||||
/// Sort Phis by integer width for replaceCongruentIVs.
|
||||
static bool width_descending(PHINode *lhs, PHINode *rhs) {
|
||||
/// Sort values by integer width for replaceCongruentIVs.
|
||||
static bool width_descending(Value *lhs, Value *rhs) {
|
||||
// Put pointers at the back and make sure pointer < pointer = false.
|
||||
if (!lhs->getType()->isIntegerTy() || !rhs->getType()->isIntegerTy())
|
||||
return rhs->getType()->isIntegerTy() && !lhs->getType()->isIntegerTy();
|
||||
@ -1632,8 +1632,9 @@ unsigned SCEVExpander::replaceCongruentIVs(Loop *L, const DominatorTree *DT,
|
||||
// Replacing the congruent phi is sufficient because acyclic redundancy
|
||||
// elimination, CSE/GVN, should handle the rest. However, once SCEV proves
|
||||
// that a phi is congruent, it's often the head of an IV user cycle that
|
||||
// is isomorphic with the original phi. So it's worth eagerly cleaning up
|
||||
// the common case of a single IV increment.
|
||||
// is isomorphic with the original phi. It's worth eagerly cleaning up the
|
||||
// common case of a single IV increment so that DeleteDeadPHIs can remove
|
||||
// cycles that had postinc uses.
|
||||
const SCEV *TruncExpr = SE.getTruncateOrNoop(SE.getSCEV(OrigInc),
|
||||
IsomorphicInc->getType());
|
||||
if (OrigInc != IsomorphicInc
|
||||
|
Loading…
x
Reference in New Issue
Block a user