[PATCH] D14400: [SimplifyLibCalls] Tranform log(pow(x, y)) -> y*log(x)
Davide Italiano via llvm-commits
llvm-commits at lists.llvm.org
Thu Nov 5 16:17:44 PST 2015
davide added a comment.
In http://reviews.llvm.org/D14400#282851, @scanon wrote:
> The one thing that's a little bit weird here is cases like x = -1, y = 4; log(pow(-1, 4)) is 0, but 4*log(-1) is NaN. That's a dramatic difference even for fast-math. Do we find exact integer exponents before we get to this point?
Yes, that's a little bit unfortunate. I don't think we find exact exponents before we get to this point. Do you think it's a showstopper to get this patch into the tree? By the way, I also noticed gcc produces the same very ouput on your testcase, for what it's worth.
http://reviews.llvm.org/D14400
More information about the llvm-commits
mailing list