Skip to content

Commit be0c809

Browse files
committed
[NFC][Debuginfo][RemoveDIs] Switch an insertion to use iterators
With the soon-to-land new-debug-info storage model, it's going to be important to use iterators for instruction insertion rather than instruction pointers. This (single line in instcombine) is the last place that trips up our internal testing for debug-info, where we insert a PHI and it should be using an iterator.
1 parent 042bb28 commit be0c809

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/lib/Transforms/InstCombine/InstructionCombining.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4522,7 +4522,7 @@ bool InstCombinerImpl::run() {
45224522
if (isa<PHINode>(I)) // PHI -> Non-PHI
45234523
InsertPos = InstParent->getFirstInsertionPt();
45244524
else // Non-PHI -> PHI
4525-
InsertPos = InstParent->getFirstNonPHI()->getIterator();
4525+
InsertPos = InstParent->getFirstNonPHIIt();
45264526
}
45274527

45284528
Result->insertInto(InstParent, InsertPos);

0 commit comments

Comments
 (0)