From cf690de5bb0a20ce0b85ebc07c0ff46304a3a065 Mon Sep 17 00:00:00 2001 From: Benjamin Kramer Date: Wed, 29 Sep 2010 22:38:50 +0000 Subject: [PATCH] Silence msvc warnings. llvm-svn: 115097 --- lib/CodeGen/IfConversion.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/CodeGen/IfConversion.cpp b/lib/CodeGen/IfConversion.cpp index 3cc9a7a062e..bd65a4441d9 100644 --- a/lib/CodeGen/IfConversion.cpp +++ b/lib/CodeGen/IfConversion.cpp @@ -786,20 +786,20 @@ IfConverter::BBInfo &IfConverter::AnalyzeBlock(MachineBasicBlock *BB, // General heuristics are: // - backedge -> 90% taken // - early exit -> 20% taken - float Prediction = 0.5; + float Prediction = 0.5f; MachineLoop *Loop = MLI->getLoopFor(BB); if (Loop) { if (TrueBBI.BB == Loop->getHeader()) - Prediction = 0.9; + Prediction = 0.9f; else if (FalseBBI.BB == Loop->getHeader()) - Prediction = 0.1; - + Prediction = 0.1f; + MachineLoop *TrueLoop = MLI->getLoopFor(TrueBBI.BB); MachineLoop *FalseLoop = MLI->getLoopFor(FalseBBI.BB); if (!TrueLoop || TrueLoop->getParentLoop() == Loop) - Prediction = 0.2; + Prediction = 0.2f; else if (!FalseLoop || FalseLoop->getParentLoop() == Loop) - Prediction = 0.8; + Prediction = 0.8f; } if (CanRevCond && ValidDiamond(TrueBBI, FalseBBI, Dups, Dups2) &&