diff options
author | Chris Lattner <sabre@nondot.org> | 2010-03-25 04:41:16 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-03-25 04:41:16 +0000 |
commit | e2a504ee8297e8aa32087c9a97264423c2a250ab (patch) | |
tree | 4cd6b63ed9877f82a3b81dae7987d3b51873ffea /llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h | |
parent | 63d45e51fb22ff452b1e19a992858fc861369a37 (diff) | |
download | bcm5719-llvm-e2a504ee8297e8aa32087c9a97264423c2a250ab.tar.gz bcm5719-llvm-e2a504ee8297e8aa32087c9a97264423c2a250ab.zip |
reapply 99444/99445, which I speculatively reverted in
r99453.
llvm-svn: 99482
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h')
-rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h b/llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h index 6b70d6afac4..baabb7554b6 100644 --- a/llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h +++ b/llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h @@ -111,7 +111,12 @@ public: /// void EmitNode(SDNode *Node, bool IsClone, bool IsCloned, DenseMap<SDValue, unsigned> &VRBaseMap, - DenseMap<MachineBasicBlock*, MachineBasicBlock*> *EM); + DenseMap<MachineBasicBlock*, MachineBasicBlock*> *EM) { + if (Node->isMachineOpcode()) + EmitMachineNode(Node, IsClone, IsCloned, VRBaseMap, EM); + else + EmitSpecialNode(Node, IsClone, IsCloned, VRBaseMap); + } /// getBlock - Return the current basic block. MachineBasicBlock *getBlock() { return MBB; } @@ -122,6 +127,13 @@ public: /// InstrEmitter - Construct an InstrEmitter and set it to start inserting /// at the given position in the given block. InstrEmitter(MachineBasicBlock *mbb, MachineBasicBlock::iterator insertpos); + +private: + void EmitMachineNode(SDNode *Node, bool IsClone, bool IsCloned, + DenseMap<SDValue, unsigned> &VRBaseMap, + DenseMap<MachineBasicBlock*, MachineBasicBlock*> *EM); + void EmitSpecialNode(SDNode *Node, bool IsClone, bool IsCloned, + DenseMap<SDValue, unsigned> &VRBaseMap); }; } |