aboutsummaryrefslogtreecommitdiffstats
path: root/test/Transforms/SimplifyLibCalls/abs.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/Transforms/SimplifyLibCalls/abs.ll')
-rw-r--r--test/Transforms/SimplifyLibCalls/abs.ll11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/Transforms/SimplifyLibCalls/abs.ll b/test/Transforms/SimplifyLibCalls/abs.ll
new file mode 100644
index 0000000..6fbe0b9
--- /dev/null
+++ b/test/Transforms/SimplifyLibCalls/abs.ll
@@ -0,0 +1,11 @@
+; RUN: opt < %s -simplify-libcalls -S | grep {select i1 %ispos}
+; PR2337
+
+define i32 @test(i32 %x) {
+entry:
+ %call = call i32 @abs( i32 %x ) ; <i32> [#uses=1]
+ ret i32 %call
+}
+
+declare i32 @abs(i32)
+