[llvm] 0efdf3b - DAG: Remove getTargetIndex as it's unused
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Sat Aug 5 06:20:13 PDT 2023
Author: Matt Arsenault
Date: 2023-08-05T09:20:09-04:00
New Revision: 0efdf3baf58c04de1549f14cef8ef0559aad9868
URL: https://github.com/llvm/llvm-project/commit/0efdf3baf58c04de1549f14cef8ef0559aad9868
DIFF: https://github.com/llvm/llvm-project/commit/0efdf3baf58c04de1549f14cef8ef0559aad9868.diff
LOG: DAG: Remove getTargetIndex as it's unused
Fixes #29973
Added:
Modified:
llvm/include/llvm/CodeGen/SelectionDAG.h
llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
Removed:
################################################################################
diff --git a/llvm/include/llvm/CodeGen/SelectionDAG.h b/llvm/include/llvm/CodeGen/SelectionDAG.h
index 55c6354f03c854..2edfa4704b8118 100644
--- a/llvm/include/llvm/CodeGen/SelectionDAG.h
+++ b/llvm/include/llvm/CodeGen/SelectionDAG.h
@@ -747,8 +747,6 @@ class SelectionDAG {
unsigned TargetFlags = 0) {
return getConstantPool(C, VT, Align, Offset, true, TargetFlags);
}
- SDValue getTargetIndex(int Index, EVT VT, int64_t Offset = 0,
- unsigned TargetFlags = 0);
// When generating a branch to a BB, we don't in general know enough
// to provide debug info for the BB at that time, so keep this one around.
SDValue getBasicBlock(MachineBasicBlock *MBB);
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
index 9a348ed2c934c1..31f7426dde084e 100644
--- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
@@ -1854,23 +1854,6 @@ SDValue SelectionDAG::getConstantPool(MachineConstantPoolValue *C, EVT VT,
return SDValue(N, 0);
}
-SDValue SelectionDAG::getTargetIndex(int Index, EVT VT, int64_t Offset,
- unsigned TargetFlags) {
- FoldingSetNodeID ID;
- AddNodeIDNode(ID, ISD::TargetIndex, getVTList(VT), std::nullopt);
- ID.AddInteger(Index);
- ID.AddInteger(Offset);
- ID.AddInteger(TargetFlags);
- void *IP = nullptr;
- if (SDNode *E = FindNodeOrInsertPos(ID, IP))
- return SDValue(E, 0);
-
- auto *N = newSDNode<TargetIndexSDNode>(Index, VT, Offset, TargetFlags);
- CSEMap.InsertNode(N, IP);
- InsertNode(N);
- return SDValue(N, 0);
-}
-
SDValue SelectionDAG::getBasicBlock(MachineBasicBlock *MBB) {
FoldingSetNodeID ID;
AddNodeIDNode(ID, ISD::BasicBlock, getVTList(MVT::Other), std::nullopt);
More information about the llvm-commits
mailing list