mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
Remove the obsolete SelectionDAG::getNodeValueTypes and simplify
code that uses it by using SelectionDAG::getVTList instead. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@68744 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -236,24 +236,6 @@ public:
|
||||
SDVTList getVTList(MVT VT1, MVT VT2, MVT VT3, MVT VT4);
|
||||
SDVTList getVTList(const MVT *VTs, unsigned NumVTs);
|
||||
|
||||
/// getNodeValueTypes - These are obsolete, use getVTList instead.
|
||||
const MVT *getNodeValueTypes(MVT VT) {
|
||||
return getVTList(VT).VTs;
|
||||
}
|
||||
const MVT *getNodeValueTypes(MVT VT1, MVT VT2) {
|
||||
return getVTList(VT1, VT2).VTs;
|
||||
}
|
||||
const MVT *getNodeValueTypes(MVT VT1, MVT VT2, MVT VT3) {
|
||||
return getVTList(VT1, VT2, VT3).VTs;
|
||||
}
|
||||
const MVT *getNodeValueTypes(MVT VT1, MVT VT2, MVT VT3, MVT VT4) {
|
||||
return getVTList(VT1, VT2, VT3, VT4).VTs;
|
||||
}
|
||||
const MVT *getNodeValueTypes(const std::vector<MVT> &vtList) {
|
||||
return getVTList(&vtList[0], (unsigned)vtList.size()).VTs;
|
||||
}
|
||||
|
||||
|
||||
//===--------------------------------------------------------------------===//
|
||||
// Node creation methods.
|
||||
//
|
||||
@@ -335,23 +317,23 @@ public:
|
||||
// null) and that there should be a flag result.
|
||||
SDValue getCopyToReg(SDValue Chain, DebugLoc dl, unsigned Reg, SDValue N,
|
||||
SDValue Flag) {
|
||||
const MVT *VTs = getNodeValueTypes(MVT::Other, MVT::Flag);
|
||||
SDVTList VTs = getVTList(MVT::Other, MVT::Flag);
|
||||
SDValue Ops[] = { Chain, getRegister(Reg, N.getValueType()), N, Flag };
|
||||
return getNode(ISD::CopyToReg, dl, VTs, 2, Ops, Flag.getNode() ? 4 : 3);
|
||||
return getNode(ISD::CopyToReg, dl, VTs, Ops, Flag.getNode() ? 4 : 3);
|
||||
}
|
||||
|
||||
// Similar to last getCopyToReg() except parameter Reg is a SDValue
|
||||
SDValue getCopyToReg(SDValue Chain, DebugLoc dl, SDValue Reg, SDValue N,
|
||||
SDValue Flag) {
|
||||
const MVT *VTs = getNodeValueTypes(MVT::Other, MVT::Flag);
|
||||
SDVTList VTs = getVTList(MVT::Other, MVT::Flag);
|
||||
SDValue Ops[] = { Chain, Reg, N, Flag };
|
||||
return getNode(ISD::CopyToReg, dl, VTs, 2, Ops, Flag.getNode() ? 4 : 3);
|
||||
return getNode(ISD::CopyToReg, dl, VTs, Ops, Flag.getNode() ? 4 : 3);
|
||||
}
|
||||
|
||||
SDValue getCopyFromReg(SDValue Chain, DebugLoc dl, unsigned Reg, MVT VT) {
|
||||
const MVT *VTs = getNodeValueTypes(VT, MVT::Other);
|
||||
SDVTList VTs = getVTList(VT, MVT::Other);
|
||||
SDValue Ops[] = { Chain, getRegister(Reg, VT) };
|
||||
return getNode(ISD::CopyFromReg, dl, VTs, 2, Ops, 2);
|
||||
return getNode(ISD::CopyFromReg, dl, VTs, Ops, 2);
|
||||
}
|
||||
|
||||
// This version of the getCopyFromReg method takes an extra operand, which
|
||||
@@ -359,9 +341,9 @@ public:
|
||||
// null) and that there should be a flag result.
|
||||
SDValue getCopyFromReg(SDValue Chain, DebugLoc dl, unsigned Reg, MVT VT,
|
||||
SDValue Flag) {
|
||||
const MVT *VTs = getNodeValueTypes(VT, MVT::Other, MVT::Flag);
|
||||
SDVTList VTs = getVTList(VT, MVT::Other, MVT::Flag);
|
||||
SDValue Ops[] = { Chain, getRegister(Reg, VT), Flag };
|
||||
return getNode(ISD::CopyFromReg, dl, VTs, 3, Ops, Flag.getNode() ? 3 : 2);
|
||||
return getNode(ISD::CopyFromReg, dl, VTs, Ops, Flag.getNode() ? 3 : 2);
|
||||
}
|
||||
|
||||
SDValue getCondCode(ISD::CondCode Cond);
|
||||
@@ -383,10 +365,10 @@ public:
|
||||
/// a flag result (to ensure it's not CSE'd). CALLSEQ_START does not have a
|
||||
/// useful DebugLoc.
|
||||
SDValue getCALLSEQ_START(SDValue Chain, SDValue Op) {
|
||||
const MVT *VTs = getNodeValueTypes(MVT::Other, MVT::Flag);
|
||||
SDVTList VTs = getVTList(MVT::Other, MVT::Flag);
|
||||
SDValue Ops[] = { Chain, Op };
|
||||
return getNode(ISD::CALLSEQ_START, DebugLoc::getUnknownLoc(),
|
||||
VTs, 2, Ops, 2);
|
||||
VTs, Ops, 2);
|
||||
}
|
||||
|
||||
/// getCALLSEQ_END - Return a new CALLSEQ_END node, which always must have a
|
||||
|
Reference in New Issue
Block a user