diff options
author | Fangrui Song <i@maskray.me> | 2024-07-01 13:54:08 -0700 |
---|---|---|
committer | Fangrui Song <i@maskray.me> | 2024-07-01 13:54:08 -0700 |
commit | 6e93e37fe917833ad2d4d09ceda150ffe755b03e (patch) | |
tree | df82b2d8821e2344f0e441d7d5e56eb9735f94bd | |
parent | 88c0a8258800bbc72e7c0b0586436d4a1c62a260 (diff) | |
download | llvm-6e93e37fe917833ad2d4d09ceda150ffe755b03e.zip llvm-6e93e37fe917833ad2d4d09ceda150ffe755b03e.tar.gz llvm-6e93e37fe917833ad2d4d09ceda150ffe755b03e.tar.bz2 |
[MC] Remove unneeded MC*AsmBackend::fixupNeedsRelaxation overrides
Follow-up to 88c0a8258800bbc72e7c0b0586436d4a1c62a260
("[MC] Make MCAsmBackend::fixupNeedsRelaxation not pure virtual").
5 files changed, 0 insertions, 40 deletions
diff --git a/llvm/lib/Target/DirectX/MCTargetDesc/DirectXMCTargetDesc.cpp b/llvm/lib/Target/DirectX/MCTargetDesc/DirectXMCTargetDesc.cpp index 4a73cbb..5a64bf6 100644 --- a/llvm/lib/Target/DirectX/MCTargetDesc/DirectXMCTargetDesc.cpp +++ b/llvm/lib/Target/DirectX/MCTargetDesc/DirectXMCTargetDesc.cpp @@ -92,12 +92,6 @@ public: const MCSubtargetInfo *STI) const override { return true; } - - bool fixupNeedsRelaxation(const MCFixup &Fixup, uint64_t Value, - const MCRelaxableFragment *DF, - const MCAsmLayout &Layout) const override { - return true; - } }; class DirectXMCAsmInfo : public MCAsmInfo { diff --git a/llvm/lib/Target/Lanai/MCTargetDesc/LanaiAsmBackend.cpp b/llvm/lib/Target/Lanai/MCTargetDesc/LanaiAsmBackend.cpp index 08ca577..cdcf8d5 100644 --- a/llvm/lib/Target/Lanai/MCTargetDesc/LanaiAsmBackend.cpp +++ b/llvm/lib/Target/Lanai/MCTargetDesc/LanaiAsmBackend.cpp @@ -56,13 +56,6 @@ public: std::unique_ptr<MCObjectTargetWriter> createObjectTargetWriter() const override; - // No instruction requires relaxation - bool fixupNeedsRelaxation(const MCFixup & /*Fixup*/, uint64_t /*Value*/, - const MCRelaxableFragment * /*DF*/, - const MCAsmLayout & /*Layout*/) const override { - return false; - } - const MCFixupKindInfo &getFixupKindInfo(MCFixupKind Kind) const override; unsigned getNumFixupKinds() const override { diff --git a/llvm/lib/Target/SPIRV/MCTargetDesc/SPIRVAsmBackend.cpp b/llvm/lib/Target/SPIRV/MCTargetDesc/SPIRVAsmBackend.cpp index 1b80e4b..4c19ebf 100644 --- a/llvm/lib/Target/SPIRV/MCTargetDesc/SPIRVAsmBackend.cpp +++ b/llvm/lib/Target/SPIRV/MCTargetDesc/SPIRVAsmBackend.cpp @@ -30,13 +30,6 @@ public: return createSPIRVObjectTargetWriter(); } - // No instruction requires relaxation. - bool fixupNeedsRelaxation(const MCFixup &Fixup, uint64_t Value, - const MCRelaxableFragment *DF, - const MCAsmLayout &Layout) const override { - return false; - } - unsigned getNumFixupKinds() const override { return 1; } bool mayNeedRelaxation(const MCInst &Inst, diff --git a/llvm/lib/Target/Sparc/MCTargetDesc/SparcAsmBackend.cpp b/llvm/lib/Target/Sparc/MCTargetDesc/SparcAsmBackend.cpp index cb7414f..81c943c 100644 --- a/llvm/lib/Target/Sparc/MCTargetDesc/SparcAsmBackend.cpp +++ b/llvm/lib/Target/Sparc/MCTargetDesc/SparcAsmBackend.cpp @@ -305,16 +305,6 @@ namespace { } } - /// fixupNeedsRelaxation - Target specific predicate for whether a given - /// fixup requires the associated instruction to be relaxed. - bool fixupNeedsRelaxation(const MCFixup &Fixup, - uint64_t Value, - const MCRelaxableFragment *DF, - const MCAsmLayout &Layout) const override { - // FIXME. - llvm_unreachable("fixupNeedsRelaxation() unimplemented"); - return false; - } void relaxInstruction(MCInst &Inst, const MCSubtargetInfo &STI) const override { // FIXME. diff --git a/llvm/lib/Target/VE/MCTargetDesc/VEAsmBackend.cpp b/llvm/lib/Target/VE/MCTargetDesc/VEAsmBackend.cpp index 05f7c00..f06a2ab 100644 --- a/llvm/lib/Target/VE/MCTargetDesc/VEAsmBackend.cpp +++ b/llvm/lib/Target/VE/MCTargetDesc/VEAsmBackend.cpp @@ -153,16 +153,6 @@ public: return false; } - /// fixupNeedsRelaxation - Target specific predicate for whether a given - /// fixup requires the associated instruction to be relaxed. - bool fixupNeedsRelaxation(const MCFixup &Fixup, uint64_t Value, - const MCRelaxableFragment *DF, - const MCAsmLayout &Layout) const override { - // Not implemented yet. For example, if we have a branch with - // lager than SIMM32 immediate value, we want to relaxation such - // branch instructions. - return false; - } void relaxInstruction(MCInst &Inst, const MCSubtargetInfo &STI) const override { // Aurora VE doesn't support relaxInstruction yet. |