@@ -7570,7 +7570,7 @@ bool llvm::impliesPoison(const Value *ValAssumedPoison, const Value *V) {
75707570static bool programUndefinedIfUndefOrPoison (const Value *V, bool PoisonOnly);
75717571
75727572Use *llvm::canFoldFreezeIntoRecurrence (
7573- PHINode *PN, DominatorTree *DT, bool &StartNeedsFreeze,
7573+ PHINode *PN, const DominatorTree *DT, bool &StartNeedsFreeze,
75747574 SmallVectorImpl<Instruction *> *DropFlags, unsigned Depth) {
75757575 // Detect whether this is a recurrence with a start value and some number of
75767576 // backedge values. We'll check whether we can push the freeze through the
@@ -7722,9 +7722,9 @@ static bool isGuaranteedNotToBeUndefOrPoison(
77227722 return true ;
77237723
77247724 bool StartNeedsFreeze;
7725- if (canFoldFreezeIntoRecurrence (
7726- const_cast <PHINode *>(PN), const_cast <DominatorTree *>(DT) ,
7727- StartNeedsFreeze, /* DropFlags= */ nullptr , Depth) &&
7725+ if (canFoldFreezeIntoRecurrence (const_cast <PHINode *>(PN), DT,
7726+ StartNeedsFreeze, /* DropFlags= */ nullptr ,
7727+ Depth) &&
77287728 !StartNeedsFreeze)
77297729 return true ;
77307730 } else if (!::canCreateUndefOrPoison (Opr, Kind,
0 commit comments