[clang] [llvm] [Mips] Implement MipsInstrInfo::getNop() operation (PR #135524)
Hervé Poussineau via llvm-commits
llvm-commits at lists.llvm.org
Thu Apr 17 23:11:13 PDT 2025
================
@@ -87,6 +87,14 @@ MipsInstrInfo::GetMemOperand(MachineBasicBlock &MBB, int FI,
MFI.getObjectAlign(FI));
}
+MCInst MipsInstrInfo::getNop() const {
+ MCInst Nop;
+ // using Mips::NOP gives
+ // "fatal error: error in backend: Not supported instr: <MCInst 580>"
----------------
hpoussin wrote:
This patch is already an improvement, because it replaces a compiler crash by the use of a valid instruction (although deprecated in recent architectures).
However, you're right that it will be better to address this error and use Mips::NOP. Unfortunately, I think I won't be able to do it myself.
https://github.com/llvm/llvm-project/pull/135524
More information about the llvm-commits
mailing list