[PATCH] D89957: [ARM][SchedModels] Let ldm* instruction scheduling use MCSchedPredicate

Dave Green via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 22 08:52:42 PDT 2020


dmgreen added inline comments.


================
Comment at: llvm/lib/Target/ARM/ARMScheduleA57.td:515
+  def A57LMAddrPred#NumAddr : MCSchedPredicate<CheckAny<[
+                                CheckNumOperands<!add(!shl(NumAddr, 1), 2)>,
+                                CheckNumOperands<!add(!shl(NumAddr, 1), 3)>]>>;
----------------
Can you explain the operands this uses? Two from the predicate, And then N*2 for the variable number of regs split into groups of 2?

I think the _UPD forms will have an extra operand, and LDMIA looks like it has 3 + 2*N.
  t2LDMIA killed $lr, 14 /* CC::al */, $noreg, def $r2, def $r3
vs
  $sp = t2LDMIA_UPD $sp, 14 /* CC::al */, $noreg, def $r7, def $lr


================
Comment at: llvm/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.h:52
+  auto BaseReg = MI.getOperand(0).getReg();
+  for (unsigned i = 1, sz = MI.getNumOperands(); i < sz; ++i) {
+    const auto &Op = MI.getOperand(i);
----------------
I think it's common to use `I` and `E` for the variables.


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

https://reviews.llvm.org/D89957



More information about the llvm-commits mailing list