Test commit: Fixed a few typos in the comments.

llvm-svn: 247793
This commit is contained in:
David L Kreitzer 2015-09-16 13:27:30 +00:00
parent be50698bfc
commit da700ce581
1 changed files with 6 additions and 6 deletions

View File

@ -166,7 +166,7 @@ bool JumpThreading::runOnFunction(Function &F) {
// Remove unreachable blocks from function as they may result in infinite // Remove unreachable blocks from function as they may result in infinite
// loop. We do threading if we found something profitable. Jump threading a // loop. We do threading if we found something profitable. Jump threading a
// branch can create other opportunities. If these opportunities form a cycle // branch can create other opportunities. If these opportunities form a cycle
// i.e. if any jump treading is undoing previous threading in the path, then // i.e. if any jump threading is undoing previous threading in the path, then
// we will loop forever. We take care of this issue by not jump threading for // we will loop forever. We take care of this issue by not jump threading for
// back edges. This works for normal cases but not for unreachable blocks as // back edges. This works for normal cases but not for unreachable blocks as
// they may have cycle with no back edge. // they may have cycle with no back edge.
@ -263,7 +263,7 @@ static unsigned getJumpThreadDuplicationCost(const BasicBlock *BB,
continue; continue;
// Bail out if this instruction gives back a token type, it is not possible // Bail out if this instruction gives back a token type, it is not possible
// to duplicate it if it used outside this BB. // to duplicate it if it is used outside this BB.
if (I->getType()->isTokenTy() && I->isUsedOutsideOfBlock(BB)) if (I->getType()->isTokenTy() && I->isUsedOutsideOfBlock(BB))
return ~0U; return ~0U;
@ -878,7 +878,7 @@ bool JumpThreading::SimplifyPartiallyRedundantLoad(LoadInst *LI) {
if (Value *AvailableVal = if (Value *AvailableVal =
FindAvailableLoadedValue(LoadedPtr, LoadBB, BBIt, 6)) { FindAvailableLoadedValue(LoadedPtr, LoadBB, BBIt, 6)) {
// If the value if the load is locally available within the block, just use // If the value of the load is locally available within the block, just use
// it. This frequently occurs for reg2mem'd allocas. // it. This frequently occurs for reg2mem'd allocas.
//cerr << "LOAD ELIMINATED:\n" << *BBIt << *LI << "\n"; //cerr << "LOAD ELIMINATED:\n" << *BBIt << *LI << "\n";
@ -1270,7 +1270,7 @@ bool JumpThreading::ProcessBranchOnXOR(BinaryOperator *BO) {
// Into: // Into:
// BB': // BB':
// %Y = icmp ne i32 %A, %B // %Y = icmp ne i32 %A, %B
// br i1 %Z, ... // br i1 %Y, ...
PredValueInfoTy XorOpValues; PredValueInfoTy XorOpValues;
bool isLHS = true; bool isLHS = true;
@ -1395,7 +1395,7 @@ bool JumpThreading::ThreadEdge(BasicBlock *BB,
return false; return false;
} }
// And finally, do it! Start by factoring the predecessors is needed. // And finally, do it! Start by factoring the predecessors if needed.
BasicBlock *PredBB; BasicBlock *PredBB;
if (PredBBs.size() == 1) if (PredBBs.size() == 1)
PredBB = PredBBs[0]; PredBB = PredBBs[0];
@ -1538,7 +1538,7 @@ bool JumpThreading::DuplicateCondBranchOnPHIIntoPred(BasicBlock *BB,
return false; return false;
} }
// And finally, do it! Start by factoring the predecessors is needed. // And finally, do it! Start by factoring the predecessors if needed.
BasicBlock *PredBB; BasicBlock *PredBB;
if (PredBBs.size() == 1) if (PredBBs.size() == 1)
PredBB = PredBBs[0]; PredBB = PredBBs[0];