From e7394ea9c6fac7e1af3a1e4b24fc545d8898110f Mon Sep 17 00:00:00 2001 From: Devang Patel Date: Tue, 15 Feb 2011 02:02:30 +0000 Subject: [PATCH] Do not forget DebugLoc! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125547 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Transforms/InstCombine/InstructionCombining.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/Transforms/InstCombine/InstructionCombining.cpp b/lib/Transforms/InstCombine/InstructionCombining.cpp index 7208ad0c7cc..37123d0621e 100644 --- a/lib/Transforms/InstCombine/InstructionCombining.cpp +++ b/lib/Transforms/InstCombine/InstructionCombining.cpp @@ -1588,6 +1588,7 @@ bool InstCombiner::DoOneIteration(Function &F, unsigned Iteration) { DEBUG(errs() << "IC: Old = " << *I << '\n' << " New = " << *Result << '\n'); + Result->setDebugLoc(I->getDebugLoc()); // Everything uses the new instruction now. I->replaceAllUsesWith(Result); -- 2.34.1