diff options
-rw-r--r-- | include/llvm/CodeGen/MachineBasicBlock.h | 2 | ||||
-rw-r--r-- | include/llvm/CodeGen/MachineDominators.h | 2 | ||||
-rw-r--r-- | lib/CodeGen/MachineBasicBlock.cpp | 5 |
3 files changed, 7 insertions, 2 deletions
diff --git a/include/llvm/CodeGen/MachineBasicBlock.h b/include/llvm/CodeGen/MachineBasicBlock.h index b11adfe3c7..bb50b5df4c 100644 --- a/include/llvm/CodeGen/MachineBasicBlock.h +++ b/include/llvm/CodeGen/MachineBasicBlock.h @@ -358,6 +358,8 @@ private: // Methods used to maintain doubly linked list of blocks... raw_ostream& operator<<(raw_ostream &OS, const MachineBasicBlock &MBB); +void WriteAsOperand(raw_ostream &, const MachineBasicBlock*, bool t); + //===--------------------------------------------------------------------===// // GraphTraits specializations for machine basic block graphs (machine-CFGs) //===--------------------------------------------------------------------===// diff --git a/include/llvm/CodeGen/MachineDominators.h b/include/llvm/CodeGen/MachineDominators.h index e56776b144..086528aaf5 100644 --- a/include/llvm/CodeGen/MachineDominators.h +++ b/include/llvm/CodeGen/MachineDominators.h @@ -23,8 +23,6 @@ namespace llvm { -inline void WriteAsOperand(raw_ostream &, const MachineBasicBlock*, bool t) { } - template<> inline void DominatorTreeBase<MachineBasicBlock>::addRoot(MachineBasicBlock* MBB) { this->Roots.push_back(MBB); diff --git a/lib/CodeGen/MachineBasicBlock.cpp b/lib/CodeGen/MachineBasicBlock.cpp index 7b14a4c851..cd52825d21 100644 --- a/lib/CodeGen/MachineBasicBlock.cpp +++ b/lib/CodeGen/MachineBasicBlock.cpp @@ -447,3 +447,8 @@ bool MachineBasicBlock::CorrectExtraCFGEdges(MachineBasicBlock *DestA, } return MadeChange; } + +void llvm::WriteAsOperand(raw_ostream &OS, const MachineBasicBlock *MBB, + bool t) { + OS << "BB#" << MBB->getNumber(); +} |