Transform pow(x, 0.5) to (x == -inf ? inf : fabs(sqrt(x))), which is
authorDan Gohman <gohman@apple.com>
Fri, 25 Sep 2009 23:10:17 +0000 (23:10 +0000)
committerDan Gohman <gohman@apple.com>
Fri, 25 Sep 2009 23:10:17 +0000 (23:10 +0000)
commit79cb8401363fc666289bfef1e37d1faa1e94422d
tree376b58a19e0c9cc2e7c37b14d9ee28aa0c69c640
parentf344f7f008b69ea1e711c2cf80be9e660e40ee13
Transform pow(x, 0.5) to (x == -inf ? inf : fabs(sqrt(x))), which is
typically faster then doing a general pow.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82819 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/SimplifyLibCalls.cpp
test/Transforms/SimplifyLibCalls/pow-to-sqrt.ll [new file with mode: 0644]