aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2008-04-09 17:48:11 +0000
committerChris Lattner <sabre@nondot.org>2008-04-09 17:48:11 +0000
commitcc7f168c6cb6c5a41de59aa524dd57593250ba5f (patch)
tree788de6d4eedf7ca1f8a6255330156f6fae7d2556 /test
parent090a8166235b7bc32cb1bc6a73b47d0212181be7 (diff)
downloadexternal_llvm-cc7f168c6cb6c5a41de59aa524dd57593250ba5f.zip
external_llvm-cc7f168c6cb6c5a41de59aa524dd57593250ba5f.tar.gz
external_llvm-cc7f168c6cb6c5a41de59aa524dd57593250ba5f.tar.bz2
Generalize getUnaryFloatFunction to handle any FP unary function, automatically
figuring out the suffix to use. implement pow(2,x) -> exp2(x). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49437 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/Transforms/SimplifyLibCalls/pow2.ll5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/Transforms/SimplifyLibCalls/pow2.ll b/test/Transforms/SimplifyLibCalls/pow2.ll
index c039d80..a48abba 100644
--- a/test/Transforms/SimplifyLibCalls/pow2.ll
+++ b/test/Transforms/SimplifyLibCalls/pow2.ll
@@ -30,3 +30,8 @@ define float @test4f(float %X) {
%Y = call float @powf( float %X, float 2.0)
ret float %Y
}
+
+define float @test5f(float %X) {
+ %Y = call float @powf(float 2.0, float %X) ;; exp2
+ ret float %Y
+}