From 3a86bcf134d8db14032b77d1d3070e0ec4364645 Mon Sep 17 00:00:00 2001 From: Zhou Sheng Date: Mon, 23 Feb 2009 10:14:11 +0000 Subject: [PATCH] Should reset DBI_Prev if DBI_Next == 0. llvm-svn: 65314 --- llvm/lib/Transforms/Scalar/InstructionCombining.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp index 1a4396bace35..7f2cab96ec55 100644 --- a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp +++ b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp @@ -12419,6 +12419,8 @@ static void AddReachableCodeToWorklist(BasicBlock *BB, DBI_Prev->eraseFromParent(); } DBI_Prev = DBI_Next; + } else { + DBI_Prev = 0; } IC.AddToWorkList(Inst);