diff options
author | Dan Gohman <gohman@apple.com> | 2010-04-22 20:46:50 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2010-04-22 20:46:50 +0000 |
commit | f81eca0ab908fdcf98ae0efaa75acccc8ba40dc2 (patch) | |
tree | d22f48cbface21800721177a712cc71616b031da /lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | |
parent | f720a4edb0343a288bfc77ccbedfdb164ed37742 (diff) | |
download | external_llvm-f81eca0ab908fdcf98ae0efaa75acccc8ba40dc2.zip external_llvm-f81eca0ab908fdcf98ae0efaa75acccc8ba40dc2.tar.gz external_llvm-f81eca0ab908fdcf98ae0efaa75acccc8ba40dc2.tar.bz2 |
Move HandlePHINodesInSuccessorBlocks functions out of SelectionDAGISel
and into SelectionDAGBuilder and FastISel.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102123 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp')
-rw-r--r-- | lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp b/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp index c8f9aba..8353c18 100644 --- a/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp +++ b/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp @@ -241,7 +241,7 @@ SelectionDAGISel::SelectBasicBlock(MachineBasicBlock *BB, if (!SDB->HasTailCall) { // Handle PHI nodes in successor blocks. if (End == LLVMBB->end()) { - HandlePHINodesInSuccessorBlocks(LLVMBB); + SDB->HandlePHINodesInSuccessorBlocks(LLVMBB); // Lower the terminator after the copies are emitted. SDB->visit(*LLVMBB->getTerminator()); @@ -711,7 +711,8 @@ void SelectionDAGISel::SelectAllBasicBlocks(const Function &Fn) { FastISel *FastIS = 0; if (EnableFastISel) FastIS = TLI.createFastISel(*MF, FuncInfo->ValueMap, FuncInfo->MBBMap, - FuncInfo->StaticAllocaMap + FuncInfo->StaticAllocaMap, + FuncInfo->PHINodesToUpdate #ifndef NDEBUG , FuncInfo->CatchInfoLost #endif @@ -765,7 +766,7 @@ void SelectionDAGISel::SelectAllBasicBlocks(const Function &Fn) { // Just before the terminator instruction, insert instructions to // feed PHI nodes in successor blocks. if (isa<TerminatorInst>(BI)) - if (!HandlePHINodesInSuccessorBlocksFast(LLVMBB, FastIS)) { + if (!FastIS->HandlePHINodesInSuccessorBlocks(LLVMBB)) { ++NumFastIselFailures; if (EnableFastISelVerbose || EnableFastISelAbort) { dbgs() << "FastISel miss: "; |