[PATCH] D67199: [InstCombine] Expand the simplification of log()

Evandro Menezes via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 6 14:24:59 PDT 2019


evandro marked 2 inline comments as done.
evandro added inline comments.


================
Comment at: llvm/lib/Transforms/Utils/SimplifyLibCalls.cpp:1807
+    Value *MulY = B.CreateFMul(Arg->getArgOperand(1), LogX, "mul");
+    // Since pow() may have side effects, e.g. errno,
+    // dead code elimination may not be trusted to remove it.
----------------
xbolva00 wrote:
> Can you extract this code and comment to helper function?
> 
> Can be used also a few lines below.
Can do, using the existing `LibCallSimplifier::replaceAllUsesWith()` for this purpose.


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

https://reviews.llvm.org/D67199





More information about the llvm-commits mailing list