[PATCH] D99032: GlobalISel: Add FoldBinOpIntoSelect combine

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Mar 22 12:32:28 PDT 2021


arsenm added inline comments.


================
Comment at: llvm/lib/CodeGen/GlobalISel/Utils.cpp:904
+    const ConstantFP *FPImm = MI.getOperand(1).getFPImm();
+    return FPImm->isZero() && !FPImm->isNegative();
+  }
----------------
foad wrote:
> arsenm wrote:
> > foad wrote:
> > > Could use isNullValue here too?
> > That is only on ConstantInt, not ConstantFP
> No, it's on Constant.
Oh, that just dispatches on ConstantFP and does the same thing


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

https://reviews.llvm.org/D99032



More information about the llvm-commits mailing list