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 | 294a0a103d561864f2089b9f5948fb1a49801918 (patch) | |
tree | 536b87862557c3982dedcd28c21123d423dd3078 /lib/CodeGen/SelectionDAG/SelectionDAG.cpp | |
parent | 131a8805205c383f67b3b6a11777401e27b90371 (diff) |
Add support for target DAG nodes that take 4 operands, such as PowerPC's
rlwinm.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@22856 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SelectionDAG/SelectionDAG.cpp')
-rw-r--r-- | lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/lib/CodeGen/SelectionDAG/SelectionDAG.cpp index f413010185..7f0725efaa 100644 --- a/lib/CodeGen/SelectionDAG/SelectionDAG.cpp +++ b/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. |