From 014b76cd0f76a126d25ed2abb1b447b5d66d5034 Mon Sep 17 00:00:00 2001 From: Krzysztof Parzyszek Date: Tue, 20 Oct 2015 19:30:21 +0000 Subject: [PATCH] [Hexagon] Do not fall-through if there is no CFG edge git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@250850 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/Hexagon/BitTracker.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Target/Hexagon/BitTracker.cpp b/lib/Target/Hexagon/BitTracker.cpp index 25ca44caf68..23336b6546e 100644 --- a/lib/Target/Hexagon/BitTracker.cpp +++ b/lib/Target/Hexagon/BitTracker.cpp @@ -1106,7 +1106,7 @@ void BT::run() { if (It == End) { MachineFunction::const_iterator BIt = B.getIterator(); MachineFunction::const_iterator Next = std::next(BIt); - if (Next != MF.end()) { + if (Next != MF.end() && B.isSuccessor(Next)) { int ThisN = B.getNumber(); int NextN = Next->getNumber(); FlowQ.push(CFGEdge(ThisN, NextN)); -- 2.34.1