aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--test/Transforms/SimplifyLibCalls/Pow.ll1
-rw-r--r--test/Transforms/SimplifyLibCalls/floor.ll11
2 files changed, 11 insertions, 1 deletions
diff --git a/test/Transforms/SimplifyLibCalls/Pow.ll b/test/Transforms/SimplifyLibCalls/Pow.ll
index 721f627..4b10ed0 100644
--- a/test/Transforms/SimplifyLibCalls/Pow.ll
+++ b/test/Transforms/SimplifyLibCalls/Pow.ll
@@ -1,4 +1,3 @@
-; Test that the StrCatOptimizer works correctly
; RUN: llvm-as < %s | opt -simplify-libcalls | llvm-dis | not grep 'call.*pow'
declare double %pow(double,double)
diff --git a/test/Transforms/SimplifyLibCalls/floor.ll b/test/Transforms/SimplifyLibCalls/floor.ll
new file mode 100644
index 0000000..542ff57
--- /dev/null
+++ b/test/Transforms/SimplifyLibCalls/floor.ll
@@ -0,0 +1,11 @@
+; RUN: llvm-as < %s | opt -simplify-libcalls | llvm-dis | not grep 'call.*floor('
+
+declare double %floor(double)
+
+float %test(float %C) {
+ %D = cast float %C to double
+ %E = call double %floor(double %D) ; --> floorf
+ %F = cast double %E to float
+ ret float %F
+}
+