diff options
author | Nate Begeman <natebegeman@mac.com> | 2005-08-18 07:30:15 +0000 |
---|---|---|
committer | Nate Begeman <natebegeman@mac.com> | 2005-08-18 07:30:15 +0000 |
commit | 19a271a67b405b85dbc93321ca022b2c6abb0fa9 (patch) | |
tree | 70a6e7b79fc2f90ab6612e30d2166f3c60e00612 /llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | |
parent | cfb9a74c2ef06f1040d17eadd98b108097f4f4c3 (diff) | |
download | bcm5719-llvm-19a271a67b405b85dbc93321ca022b2c6abb0fa9.tar.gz bcm5719-llvm-19a271a67b405b85dbc93321ca022b2c6abb0fa9.zip |
Add support for target DAG nodes that take 4 operands, such as PowerPC's
rlwinm.
llvm-svn: 22856
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp')
-rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp index f413010185b..7f0725efaab 100644 --- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp @@ -1810,6 +1810,14 @@ void SelectionDAG::SelectNodeTo(SDNode *N, MVT::ValueType VT, N->setValueTypes(VT); N->setOperands(Op1, Op2, Op3); } +void SelectionDAG::SelectNodeTo(SDNode *N, MVT::ValueType VT, + unsigned TargetOpc, SDOperand Op1, + SDOperand Op2, SDOperand Op3, SDOperand Op4) { + RemoveNodeFromCSEMaps(N); + N->MorphNodeTo(ISD::BUILTIN_OP_END+TargetOpc); + N->setValueTypes(VT); + N->setOperands(Op1, Op2, Op3, Op4); +} /// ReplaceAllUsesWith - Modify anything using 'From' to use 'To' instead. /// This can cause recursive merging of nodes in the DAG. |