[PATCH] D115127: [MIPS] Add FPU Delay Slot for MIPS1/2/3

Djordje Todorovic via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 6 02:06:28 PST 2021


djtodoro added inline comments.


================
Comment at: llvm/lib/Target/Mips/MipsBranchExpansion.cpp:844
 
+bool MipsBranchExpansion::handleFPUDelaySlot() {
+  // FPU delay slots are only defined for MIPS3 and below.
----------------
This code is being copied from `handleForbiddenSlot()` (most of it, actually). Can we factor/move the common code into a function/predicate?


================
Comment at: llvm/lib/Target/Mips/MipsInstrInfo.cpp:588
+  for (const MachineOperand &Op : FPUMI.defs()) {
+    if (Op.isReg()) {
+      bool Reads, Writes;
----------------
an early exit here? 

  if (!Op.isReg())
    continue;



CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D115127/new/

https://reviews.llvm.org/D115127



More information about the llvm-commits mailing list