Change a TerminatorInst* to an Instruction* in HotColdSplitting.cpp.
authorLang Hames <lhames@gmail.com>
Mon, 15 Oct 2018 22:27:03 +0000 (22:27 +0000)
committerLang Hames <lhames@gmail.com>
Mon, 15 Oct 2018 22:27:03 +0000 (22:27 +0000)
r344558 added an assignment to a TerminatorInst* from
BasicBlock::getTerminatorInst(), but BasicBlock::getTerminatorInst() returns an
Instruction* rather than a TerminatorInst* since r344504 so this fails to
compile.

Changing the variable to an Instruction* should get the bots building again.

llvm-svn: 344566

llvm/lib/Transforms/IPO/HotColdSplitting.cpp

index fcea40d..be4da24 100644 (file)
@@ -150,7 +150,7 @@ static bool unlikelyExecuted(const BasicBlock &BB) {
 }
 
 static bool returnsOrHasSideEffects(const BasicBlock &BB) {
-  const TerminatorInst *I = BB.getTerminator();
+  const Instruction *I = BB.getTerminator();
   if (isa<ReturnInst>(I) || isa<IndirectBrInst>(I) || isa<InvokeInst>(I))
     return true;