diff options
author | Nate Begeman <natebegeman@mac.com> | 2005-08-18 00:53:47 +0000 |
---|---|---|
committer | Nate Begeman <natebegeman@mac.com> | 2005-08-18 00:53:47 +0000 |
commit | 6a7d61179c77c23dc22cd64e5e922bc40ed234e9 (patch) | |
tree | 9a1222e7f1b0f0d388bee8046b92a3f054ff53a6 /lib/Target/PowerPC/PPCISelDAGToDAG.cpp | |
parent | b5a0668d43582297e19d03df34e0a0c09a1f6c45 (diff) |
Add a couple more nodes that are easy to handle
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@22850 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/PowerPC/PPCISelDAGToDAG.cpp')
-rw-r--r-- | lib/Target/PowerPC/PPCISelDAGToDAG.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/Target/PowerPC/PPCISelDAGToDAG.cpp b/lib/Target/PowerPC/PPCISelDAGToDAG.cpp index fded5bc373..4b1c63e2b2 100644 --- a/lib/Target/PowerPC/PPCISelDAGToDAG.cpp +++ b/lib/Target/PowerPC/PPCISelDAGToDAG.cpp @@ -310,6 +310,11 @@ SDOperand PPC32DAGToDAGISel::Select(SDOperand Op) { Select(N->getOperand(0)), Select(N->getOperand(1))); break; } + case ISD::FABS: { + CurDAG->SelectNodeTo(N, N->getValueType(0), PPC::FABS, + Select(N->getOperand(0))); + break; + } case ISD::FNEG: { SDOperand Val = Select(N->getOperand(0)); MVT::ValueType Ty = N->getValueType(0); @@ -338,6 +343,12 @@ SDOperand PPC32DAGToDAGISel::Select(SDOperand Op) { CurDAG->SelectNodeTo(N, Ty, PPC::FNEG, Val); break; } + case ISD::FSQRT: { + MVT::ValueType Ty = N->getValueType(0); + CurDAG->SelectNodeTo(N, Ty, Ty == MVT::f64 ? PPC::FSQRT : PPC::FSQRTS, + Select(N->getOperand(0))); + break; + } case ISD::RET: { SDOperand Chain = Select(N->getOperand(0)); // Token chain. |