summaryrefslogtreecommitdiff
path: root/test/Transforms
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2013-09-23 14:41:35 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2013-09-23 14:41:35 +0000
commit2bbb2d4576ec821c5a5a1648d4ccffc920ed2449 (patch)
tree96eeea1f5fb11d06ecd7ae40b829ceeecf3634ba /test/Transforms
parente0187e51a17f2081d6a72a57e0fbba8ce38d9410 (diff)
downloadllvm-2bbb2d4576ec821c5a5a1648d4ccffc920ed2449.tar.gz
llvm-2bbb2d4576ec821c5a5a1648d4ccffc920ed2449.tar.bz2
llvm-2bbb2d4576ec821c5a5a1648d4ccffc920ed2449.tar.xz
Expand test case a bit.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191205 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Transforms')
-rw-r--r--test/Transforms/InstSimplify/compare.ll7
1 files changed, 5 insertions, 2 deletions
diff --git a/test/Transforms/InstSimplify/compare.ll b/test/Transforms/InstSimplify/compare.ll
index 73188aa697..83705aac85 100644
--- a/test/Transforms/InstSimplify/compare.ll
+++ b/test/Transforms/InstSimplify/compare.ll
@@ -722,7 +722,10 @@ define i1 @non_inbounds_gep_compare(i64* %a) {
; CHECK-LABEL: @non_inbounds_gep_compare(
; Equality compares with non-inbounds GEPs can be folded.
%x = getelementptr i64* %a, i64 42
- %cmp = icmp eq i64* %a, %x
+ %y = getelementptr inbounds i64* %x, i64 -42
+ %z = getelementptr i64* %a, i64 -42
+ %w = getelementptr inbounds i64* %z, i64 42
+ %cmp = icmp eq i64* %y, %w
ret i1 %cmp
-; CHECK-NEXT: ret i1 false
+; CHECK-NEXT: ret i1 true
}