diff options
author | Cameron Zwarich <zwarich@apple.com> | 2011-02-24 10:00:13 +0000 |
---|---|---|
committer | Cameron Zwarich <zwarich@apple.com> | 2011-02-24 10:00:13 +0000 |
commit | a46cd97818ac6fa336b093adecf2006fb041ca1c (patch) | |
tree | 800b11ad4052a2cd7e8dd896e29d107c11b0bcfc /lib | |
parent | e1497b979166765d97c91813a8e830a1ab8fbe12 (diff) | |
download | external_llvm-a46cd97818ac6fa336b093adecf2006fb041ca1c.zip external_llvm-a46cd97818ac6fa336b093adecf2006fb041ca1c.tar.gz external_llvm-a46cd97818ac6fa336b093adecf2006fb041ca1c.tar.bz2 |
Track blocks visited in reverse postorder.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126377 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp | 1 | ||||
-rw-r--r-- | lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 4 |
2 files changed, 5 insertions, 0 deletions
diff --git a/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp b/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp index 98582ba..c55cf85 100644 --- a/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp +++ b/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp @@ -219,6 +219,7 @@ void FunctionLoweringInfo::clear() { CatchInfoFound.clear(); #endif LiveOutRegInfo.clear(); + VisitedBBs.clear(); ArgDbgValues.clear(); ByValArgFrameIndexMap.clear(); RegFixups.clear(); diff --git a/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp b/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp index 835aab2..9d3f5bc 100644 --- a/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp +++ b/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp @@ -831,6 +831,10 @@ void SelectionDAGISel::SelectAllBasicBlocks(const Function &Fn) { #ifndef NDEBUG CheckLineNumbers(LLVMBB); #endif + + if (OptLevel != CodeGenOpt::None) + FuncInfo->VisitedBBs.insert(LLVMBB); + FuncInfo->MBB = FuncInfo->MBBMap[LLVMBB]; FuncInfo->InsertPt = FuncInfo->MBB->getFirstNonPHI(); |