diff options
author | Chris Lattner <sabre@nondot.org> | 2007-02-25 06:21:57 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2007-02-25 06:21:57 +0000 |
commit | 9cb9626abf26dfcbbe8d02013c5b780c318cb321 (patch) | |
tree | 897088312d4aad5cc57ab4879fd20408e09790d1 | |
parent | 4283c118cf72b55696d398ae3a20ba1136f6ffc7 (diff) |
remove std::vector's in RET lowering.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34576 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/Target/X86/X86ISelLowering.cpp | 33 |
1 files changed, 11 insertions, 22 deletions
diff --git a/lib/Target/X86/X86ISelLowering.cpp b/lib/Target/X86/X86ISelLowering.cpp index 9371407f1c..83e7bab138 100644 --- a/lib/Target/X86/X86ISelLowering.cpp +++ b/lib/Target/X86/X86ISelLowering.cpp @@ -4014,13 +4014,9 @@ SDOperand X86TargetLowering::LowerRET(SDOperand Op, SelectionDAG &DAG) { if (DAG.getMachineFunction().liveout_empty()) DAG.getMachineFunction().addLiveOut(X86::ST0); - std::vector<MVT::ValueType> Tys; - Tys.push_back(MVT::Other); - Tys.push_back(MVT::Flag); - std::vector<SDOperand> Ops; - Ops.push_back(Op.getOperand(0)); - Ops.push_back(Op.getOperand(1)); - Copy = DAG.getNode(X86ISD::FP_SET_RESULT, Tys, &Ops[0], Ops.size()); + SDVTList Tys = DAG.getVTList(MVT::Other, MVT::Flag); + SDOperand Ops[] = { Op.getOperand(0), Op.getOperand(1) }; + Copy = DAG.getNode(X86ISD::FP_SET_RESULT, Tys, Ops, 2); } else { // FP return with ScalarSSE (return on fp-stack). if (DAG.getMachineFunction().liveout_empty()) @@ -4042,21 +4038,14 @@ SDOperand X86TargetLowering::LowerRET(SDOperand Op, SelectionDAG &DAG) { MemLoc = DAG.getFrameIndex(SSFI, getPointerTy()); Chain = DAG.getStore(Op.getOperand(0), Value, MemLoc, NULL, 0); } - std::vector<MVT::ValueType> Tys; - Tys.push_back(MVT::f64); - Tys.push_back(MVT::Other); - std::vector<SDOperand> Ops; - Ops.push_back(Chain); - Ops.push_back(MemLoc); - Ops.push_back(DAG.getValueType(ArgVT)); - Copy = DAG.getNode(X86ISD::FLD, Tys, &Ops[0], Ops.size()); - Tys.clear(); - Tys.push_back(MVT::Other); - Tys.push_back(MVT::Flag); - Ops.clear(); - Ops.push_back(Copy.getValue(1)); - Ops.push_back(Copy); - Copy = DAG.getNode(X86ISD::FP_SET_RESULT, Tys, &Ops[0], Ops.size()); + SDVTList Tys = DAG.getVTList(MVT::f64, MVT::Other); + SDOperand Ops[] = { Chain, MemLoc, DAG.getValueType(ArgVT) }; + Copy = DAG.getNode(X86ISD::FLD, Tys, Ops, 3); + + Tys = DAG.getVTList(MVT::Other, MVT::Flag); + Ops[0] = Copy.getValue(1); + Ops[1] = Copy; + Copy = DAG.getNode(X86ISD::FP_SET_RESULT, Tys, Ops, 2); } break; } |