Skip to content

Commit 0d45bcf

Browse files
committed
[AMDGPU] Remove unused functions for checking 16-bit inline literals
This patch removes unused functions that check if an immediate is a 16-bit inline literals. This serves as prime patches to fix llvm#79369.
1 parent 228e9d5 commit 0d45bcf

File tree

4 files changed

+0
-26
lines changed

4 files changed

+0
-26
lines changed

llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.h

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -107,14 +107,6 @@ class AMDGPUDAGToDAGISel : public SelectionDAGISel {
107107
std::pair<SDValue, SDValue> foldFrameIndex(SDValue N) const;
108108
bool isInlineImmediate(const SDNode *N) const;
109109

110-
bool isInlineImmediate16(int64_t Imm) const {
111-
return AMDGPU::isInlinableLiteral16(Imm, Subtarget->hasInv2PiInlineImm());
112-
}
113-
114-
bool isInlineImmediate32(int64_t Imm) const {
115-
return AMDGPU::isInlinableLiteral32(Imm, Subtarget->hasInv2PiInlineImm());
116-
}
117-
118110
bool isInlineImmediate64(int64_t Imm) const {
119111
return AMDGPU::isInlinableLiteral64(Imm, Subtarget->hasInv2PiInlineImm());
120112
}

llvm/lib/Target/AMDGPU/AMDGPUInstructionSelector.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5746,14 +5746,6 @@ void AMDGPUInstructionSelector::renderFPPow2ToExponent(MachineInstrBuilder &MIB,
57465746
MIB.addImm(ExpVal);
57475747
}
57485748

5749-
bool AMDGPUInstructionSelector::isInlineImmediate16(int64_t Imm) const {
5750-
return AMDGPU::isInlinableLiteral16(Imm, STI.hasInv2PiInlineImm());
5751-
}
5752-
5753-
bool AMDGPUInstructionSelector::isInlineImmediate32(int64_t Imm) const {
5754-
return AMDGPU::isInlinableLiteral32(Imm, STI.hasInv2PiInlineImm());
5755-
}
5756-
57575749
bool AMDGPUInstructionSelector::isInlineImmediate64(int64_t Imm) const {
57585750
return AMDGPU::isInlinableLiteral64(Imm, STI.hasInv2PiInlineImm());
57595751
}

llvm/lib/Target/AMDGPU/AMDGPUInstructionSelector.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -353,8 +353,6 @@ class AMDGPUInstructionSelector final : public InstructionSelector {
353353
void renderFPPow2ToExponent(MachineInstrBuilder &MIB, const MachineInstr &MI,
354354
int OpIdx) const;
355355

356-
bool isInlineImmediate16(int64_t Imm) const;
357-
bool isInlineImmediate32(int64_t Imm) const;
358356
bool isInlineImmediate64(int64_t Imm) const;
359357
bool isInlineImmediate(const APFloat &Imm) const;
360358

llvm/lib/Target/AMDGPU/SIInstrInfo.td

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -797,14 +797,6 @@ def i64imm_32bit : ImmLeaf<i64, [{
797797
return (Imm & 0xffffffffULL) == static_cast<uint64_t>(Imm);
798798
}]>;
799799

800-
def InlineImm16 : ImmLeaf<i16, [{
801-
return isInlineImmediate16(Imm);
802-
}]>;
803-
804-
def InlineImm32 : ImmLeaf<i32, [{
805-
return isInlineImmediate32(Imm);
806-
}]>;
807-
808800
def InlineImm64 : ImmLeaf<i64, [{
809801
return isInlineImmediate64(Imm);
810802
}]>;

0 commit comments

Comments
 (0)