[PATCH] D81181: [TargetLowering][NFC] More efficient emitPatchpoint().

Eli Friedman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 4 12:09:42 PDT 2020


efriedma added inline comments.


================
Comment at: llvm/lib/CodeGen/TargetLoweringBase.cpp:1030
+    if (MI->getOperand(OperIdx).isFI())
+      break;
+
----------------
You're making this code a lot harder to follow with the whole OperIdx thing, and it only saves one branch per MachineOperand.  Please just do `if (!llvm::any_of(MI->operands(), [](MachineOperand &Operand) { return Operand.isFI(); }) return MBB;`


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D81181





More information about the llvm-commits mailing list