summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-01-28 09:32:01 +0000
committerChris Lattner <sabre@nondot.org>2006-01-28 09:32:01 +0000
commit009c53f6885b4e3229c348aa415bf304dc480674 (patch)
tree0991cb006c5e0835d4390958d809b4ac12203ec9
parenteb6375149964c7c7dc3206cd1cb61709f29e3c87 (diff)
downloadbcm5719-llvm-009c53f6885b4e3229c348aa415bf304dc480674.tar.gz
bcm5719-llvm-009c53f6885b4e3229c348aa415bf304dc480674.zip
Add some methods
llvm-svn: 25741
-rw-r--r--llvm/include/llvm/CodeGen/SelectionDAG.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/llvm/include/llvm/CodeGen/SelectionDAG.h b/llvm/include/llvm/CodeGen/SelectionDAG.h
index 91dfeceee1c..00e32615cc7 100644
--- a/llvm/include/llvm/CodeGen/SelectionDAG.h
+++ b/llvm/include/llvm/CodeGen/SelectionDAG.h
@@ -262,6 +262,19 @@ public:
// getSrcValue - construct a node to track a Value* through the backend
SDOperand getSrcValue(const Value* I, int offset = 0);
+ /// UpdateNodeOperands - *Mutate* the specified node in-place to have the
+ /// specified operands. If the resultant node already exists in the DAG,
+ /// this does not modify the specified node, instead it returns the node that
+ /// already exists. If the resultant node does not exist in the DAG, the
+ /// input node is returned. As a degenerate case, if you specify the same
+ /// input operands as the node already has, the input node is returned.
+ SDOperand UpdateNodeOperands(SDOperand N, SDOperand Op);
+ SDOperand UpdateNodeOperands(SDOperand N, SDOperand Op1, SDOperand Op2);
+ SDOperand UpdateNodeOperands(SDOperand N, SDOperand Op1, SDOperand Op2,
+ SDOperand Op3);
+ SDOperand UpdateNodeOperands(SDOperand N, SDOperand Op1, SDOperand Op2,
+ SDOperand Op3, SDOperand Op4);
+ SDOperand UpdateNodeOperands(SDOperand N, const std::vector<SDOperand> &Op);
/// SelectNodeTo - These are used for target selectors to *mutate* the
/// specified node to have the specified return type, Target opcode, and
@@ -551,6 +564,10 @@ public:
private:
void RemoveNodeFromCSEMaps(SDNode *N);
SDNode *AddNonLeafNodeToCSEMaps(SDNode *N);
+ SDNode **FindModifiedNodeSlot(SDNode *N, SDOperand Op);
+ SDNode **FindModifiedNodeSlot(SDNode *N, SDOperand Op1, SDOperand Op2);
+ SDNode **FindModifiedNodeSlot(SDNode *N, const std::vector<SDOperand> &Ops);
+
void DestroyDeadNode(SDNode *N);
void DeleteNodeNotInCSEMaps(SDNode *N);
void setNodeValueTypes(SDNode *N, std::vector<MVT::ValueType> &RetVals);
OpenPOWER on IntegriCloud