[llvm] a02b79f - [Mips][NFC] Garbage collect unused code (#85499)
via llvm-commits
llvm-commits at lists.llvm.org
Sat Mar 16 02:38:13 PDT 2024
Author: Brad Smith
Date: 2024-03-16T05:38:09-04:00
New Revision: a02b79f3fc765af77ad565e907989c25b2427fe5
URL: https://github.com/llvm/llvm-project/commit/a02b79f3fc765af77ad565e907989c25b2427fe5
DIFF: https://github.com/llvm/llvm-project/commit/a02b79f3fc765af77ad565e907989c25b2427fe5.diff
LOG: [Mips][NFC] Garbage collect unused code (#85499)
Added:
Modified:
llvm/lib/Target/Mips/MCTargetDesc/MipsTargetStreamer.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Target/Mips/MCTargetDesc/MipsTargetStreamer.cpp b/llvm/lib/Target/Mips/MCTargetDesc/MipsTargetStreamer.cpp
index adfcea73615831..bdf299ae8ac112 100644
--- a/llvm/lib/Target/Mips/MCTargetDesc/MipsTargetStreamer.cpp
+++ b/llvm/lib/Target/Mips/MCTargetDesc/MipsTargetStreamer.cpp
@@ -1255,28 +1255,6 @@ void MipsTargetELFStreamer::emitDirectiveCpsetup(unsigned RegNo,
emitRRI(Mips::SD, GPReg, Mips::SP, RegOrOffset, SMLoc(), &STI);
}
-#if 0
- // We haven't support -mabicalls -mno-shared yet.
- if (-mno-shared) {
- MCSymbol *GPSym = MCA.getContext().getOrCreateSymbol("__gnu_local_gp");
- const MipsMCExpr *HiExpr = MipsMCExpr::create(
- MipsMCExpr::MEK_HI, MCSymbolRefExpr::create(GPSym, MCA.getContext()),
- MCA.getContext());
- const MipsMCExpr *LoExpr = MipsMCExpr::create(
- MipsMCExpr::MEK_LO, MCSymbolRefExpr::create(GPSym, MCA.getContext()),
- MCA.getContext());
-
- // lui $gp, %hi(__gnu_local_gp)
- emitRX(Mips::LUi, GPReg, MCOperand::createExpr(HiExpr), SMLoc(), &STI);
-
- // addiu $gp, $gp, %lo(__gnu_local_gp)
- emitRRX(Mips::ADDiu, GPReg, GPReg, MCOperand::createExpr(LoExpr), SMLoc(),
- &STI);
-
- return;
- }
-#endif
-
const MipsMCExpr *HiExpr = MipsMCExpr::createGpOff(
MipsMCExpr::MEK_HI, MCSymbolRefExpr::create(&Sym, MCA.getContext()),
MCA.getContext());
More information about the llvm-commits
mailing list