[llvm-commits] CVS: llvm/include/llvm/CodeGen/SelectionDAG.h SelectionDAGNodes.h
Chris Lattner
lattner at cs.uiuc.edu
Wed Aug 24 17:42:20 PDT 2005
Changes in directory llvm/include/llvm/CodeGen:
SelectionDAG.h updated: 1.49 -> 1.50
SelectionDAGNodes.h updated: 1.60 -> 1.61
---
Log message:
add a new TargetFrameIndex node
---
Diffs of the changes: (+7 -4)
SelectionDAG.h | 3 ++-
SelectionDAGNodes.h | 8 +++++---
2 files changed, 7 insertions(+), 4 deletions(-)
Index: llvm/include/llvm/CodeGen/SelectionDAG.h
diff -u llvm/include/llvm/CodeGen/SelectionDAG.h:1.49 llvm/include/llvm/CodeGen/SelectionDAG.h:1.50
--- llvm/include/llvm/CodeGen/SelectionDAG.h:1.49 Wed Aug 24 18:00:29 2005
+++ llvm/include/llvm/CodeGen/SelectionDAG.h Wed Aug 24 19:42:08 2005
@@ -99,6 +99,7 @@
SDOperand getGlobalAddress(const GlobalValue *GV, MVT::ValueType VT);
SDOperand getTargetGlobalAddress(const GlobalValue *GV, MVT::ValueType VT);
SDOperand getFrameIndex(int FI, MVT::ValueType VT);
+ SDOperand getTargetFrameIndex(int FI, MVT::ValueType VT);
SDOperand getConstantPool(unsigned CPIdx, MVT::ValueType VT);
SDOperand getBasicBlock(MachineBasicBlock *MBB);
SDOperand getExternalSymbol(const char *Sym, MVT::ValueType VT);
@@ -307,7 +308,7 @@
std::map<std::pair<uint64_t, MVT::ValueType>, SDNode*> Constants;
std::map<std::pair<uint64_t, MVT::ValueType>, SDNode*> TargetConstants;
std::map<std::pair<uint64_t, MVT::ValueType>, SDNode*> ConstantFPs;
- std::map<int, SDNode*> FrameIndices;
+ std::map<int, SDNode*> FrameIndices, TargetFrameIndices;
std::map<unsigned, SDNode*> ConstantPoolIndices;
std::map<MachineBasicBlock *, SDNode*> BBNodes;
std::vector<SDNode*> ValueTypeNodes;
Index: llvm/include/llvm/CodeGen/SelectionDAGNodes.h
diff -u llvm/include/llvm/CodeGen/SelectionDAGNodes.h:1.60 llvm/include/llvm/CodeGen/SelectionDAGNodes.h:1.61
--- llvm/include/llvm/CodeGen/SelectionDAGNodes.h:1.60 Sun Aug 21 13:49:58 2005
+++ llvm/include/llvm/CodeGen/SelectionDAGNodes.h Wed Aug 24 19:42:08 2005
@@ -65,6 +65,7 @@
// anything else with this node, and this is valid in the target-specific
// dag, turning into a GlobalAddress operand.
TargetGlobalAddress,
+ TargetFrameIndex,
// CopyToReg - This node has three operands: a chain, a register number to
// set to this value, and a value.
@@ -812,15 +813,16 @@
int FI;
protected:
friend class SelectionDAG;
- FrameIndexSDNode(int fi, MVT::ValueType VT)
- : SDNode(ISD::FrameIndex, VT), FI(fi) {}
+ FrameIndexSDNode(int fi, MVT::ValueType VT, bool isTarg)
+ : SDNode(isTarg ? ISD::TargetFrameIndex : ISD::FrameIndex, VT), FI(fi) {}
public:
int getIndex() const { return FI; }
static bool classof(const FrameIndexSDNode *) { return true; }
static bool classof(const SDNode *N) {
- return N->getOpcode() == ISD::FrameIndex;
+ return N->getOpcode() == ISD::FrameIndex ||
+ N->getOpcode() == ISD::TargetFrameIndex;
}
};
More information about the llvm-commits
mailing list