[PATCH] D64099: [InstCombine] pow(C,x) -> exp(log(C)*x)
Dávid Bolvanský via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 2 14:06:38 PDT 2019
xbolva00 created this revision.
xbolva00 added reviewers: spatel, efriedma.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
Transform
pow(C,x)
To
exp(log(C)*x)
if C > 0, C != inf, C != NaN (and C is not power of 2, since we have some fold for such case already).
log(C) is folded by the compiler and exp is much faster to compute than pow.
Repository:
rL LLVM
https://reviews.llvm.org/D64099
Files:
lib/Transforms/Utils/SimplifyLibCalls.cpp
test/Transforms/InstCombine/pow-exp.ll
test/Transforms/InstCombine/pow_fp_int.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D64099.207624.patch
Type: text/x-patch
Size: 10333 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190702/84f2178b/attachment.bin>
More information about the llvm-commits
mailing list