summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Scalar/CodeGenPrepare.cpp
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2011-03-24 15:35:25 +0000
committerDevang Patel <dpatel@apple.com>2011-03-24 15:35:25 +0000
commit8f606d7b9b4df95582b8a10e0e4dd141b5f1be11 (patch)
tree2bff652ead8e80462670ce4d55c1eb1ccc5fdac8 /llvm/lib/Transforms/Scalar/CodeGenPrepare.cpp
parentd7d7e0d3dffd7c117ea8bbe3697bb91a5a0ab7ab (diff)
downloadbcm5719-llvm-8f606d7b9b4df95582b8a10e0e4dd141b5f1be11.tar.gz
bcm5719-llvm-8f606d7b9b4df95582b8a10e0e4dd141b5f1be11.zip
s/UpdateDT/ModifiedDT/g
llvm-svn: 128211
Diffstat (limited to 'llvm/lib/Transforms/Scalar/CodeGenPrepare.cpp')
-rw-r--r--llvm/lib/Transforms/Scalar/CodeGenPrepare.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/llvm/lib/Transforms/Scalar/CodeGenPrepare.cpp b/llvm/lib/Transforms/Scalar/CodeGenPrepare.cpp
index 37b97830716..fc7e13675cb 100644
--- a/llvm/lib/Transforms/Scalar/CodeGenPrepare.cpp
+++ b/llvm/lib/Transforms/Scalar/CodeGenPrepare.cpp
@@ -81,9 +81,9 @@ namespace {
/// multiple load/stores of the same address.
DenseMap<Value*, Value*> SunkAddrs;
- /// UpdateDT - If CFG is modified in anyway, dominator tree may need to
+ /// ModifiedDT - If CFG is modified in anyway, dominator tree may need to
/// be updated.
- bool UpdateDT;
+ bool ModifiedDT;
public:
static char ID; // Pass identification, replacement for typeid
@@ -124,7 +124,7 @@ FunctionPass *llvm::createCodeGenPreparePass(const TargetLowering *TLI) {
bool CodeGenPrepare::runOnFunction(Function &F) {
bool EverMadeChange = false;
- UpdateDT = false;
+ ModifiedDT = false;
DT = getAnalysisIfAvailable<DominatorTree>();
PFI = getAnalysisIfAvailable<ProfileInfo>();
@@ -150,11 +150,11 @@ bool CodeGenPrepare::runOnFunction(Function &F) {
MadeChange |= ConstantFoldTerminator(BB);
if (MadeChange)
- UpdateDT = true;
+ ModifiedDT = true;
EverMadeChange |= MadeChange;
}
- if (UpdateDT && DT)
+ if (ModifiedDT && DT)
DT->DT->recalculate(F);
return EverMadeChange;
@@ -331,7 +331,7 @@ void CodeGenPrepare::EliminateMostlyEmptyBlock(BasicBlock *BB) {
// The PHIs are now updated, change everything that refers to BB to use
// DestBB and remove BB.
BB->replaceAllUsesWith(DestBB);
- if (DT && !UpdateDT) {
+ if (DT && !ModifiedDT) {
BasicBlock *BBIDom = DT->getNode(BB)->getIDom()->getBlock();
BasicBlock *DestBBIDom = DT->getNode(DestBB)->getIDom()->getBlock();
BasicBlock *NewIDom = DT->findNearestCommonDominator(BBIDom, DestBBIDom);
@@ -535,7 +535,7 @@ bool CodeGenPrepare::OptimizeCallInst(CallInst *CI) {
WeakVH IterHandle(CurInstIterator);
ReplaceAndSimplifyAllUses(CI, RetVal, TLI ? TLI->getTargetData() : 0,
- UpdateDT ? 0 : DT);
+ ModifiedDT ? 0 : DT);
// If the iterator instruction was recursively deleted, start over at the
// start of the block.
@@ -669,7 +669,7 @@ bool CodeGenPrepare::DupRetToEnableTailCallOpts(ReturnInst *RI) {
// Duplicate the return into CallBB.
(void)FoldReturnIntoUncondBranch(RI, BB, CallBB);
- UpdateDT = Changed = true;
+ ModifiedDT = Changed = true;
++NumRetsDup;
}
OpenPOWER on IntegriCloud