diff options
author | Nick Lewycky <nicholas@mxc.ca> | 2012-02-25 23:01:19 +0000 |
---|---|---|
committer | Nick Lewycky <nicholas@mxc.ca> | 2012-02-25 23:01:19 +0000 |
commit | 6fd3428afa46ace6712f0649bf4a7bd6799cc355 (patch) | |
tree | 0610507366cd0c856c8ba20cf26e1d6d5975c3b1 /test/Transforms | |
parent | 28e215ba63164f201292f8c77bf038b4282aa052 (diff) | |
download | external_llvm-6fd3428afa46ace6712f0649bf4a7bd6799cc355.zip external_llvm-6fd3428afa46ace6712f0649bf4a7bd6799cc355.tar.gz external_llvm-6fd3428afa46ace6712f0649bf4a7bd6799cc355.tar.bz2 |
Roll these back to r151448 until I figure out how they're breaking
MultiSource/Applications/lua.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@151463 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Transforms')
-rw-r--r-- | test/Transforms/InstCombine/icmp.ll | 4 | ||||
-rw-r--r-- | test/Transforms/InstSimplify/compare.ll | 54 |
2 files changed, 3 insertions, 55 deletions
diff --git a/test/Transforms/InstCombine/icmp.ll b/test/Transforms/InstCombine/icmp.ll index a9ae221..dabb0f3 100644 --- a/test/Transforms/InstCombine/icmp.ll +++ b/test/Transforms/InstCombine/icmp.ll @@ -634,6 +634,8 @@ define i1 @test62(i8* %a) { %arrayidx2 = getelementptr inbounds i8* %a, i64 10 %cmp = icmp slt i8* %arrayidx1, %arrayidx2 ret i1 %cmp +; Don't turn a signed cmp of GEPs into an index compare. ; CHECK: @test62 -; CHECK-NEXT: ret i1 true +; CHECK: %cmp = icmp slt i8* %arrayidx1, %arrayidx2 +; CHECK-NEXT: ret i1 %cmp } diff --git a/test/Transforms/InstSimplify/compare.ll b/test/Transforms/InstSimplify/compare.ll index ea43f5f..6ee6dfb 100644 --- a/test/Transforms/InstSimplify/compare.ll +++ b/test/Transforms/InstSimplify/compare.ll @@ -40,60 +40,6 @@ define i1 @gep2() { ; CHECK-NEXT: ret i1 true } -; PR11238 -%gept = type { i32, i32 } -@gepy = global %gept zeroinitializer, align 8 -@gepz = extern_weak global %gept - -define i1 @gep3() { -; CHECK: @gep3 - %x = alloca %gept, align 8 - %a = getelementptr %gept* %x, i64 0, i32 0 - %b = getelementptr %gept* %x, i64 0, i32 1 - %equal = icmp eq i32* %a, %b - ret i1 %equal -; CHECK-NEXT: ret i1 false -} - -define i1 @gep4() { -; CHECK: @gep4 - %x = alloca %gept, align 8 - %a = getelementptr %gept* @gepy, i64 0, i32 0 - %b = getelementptr %gept* @gepy, i64 0, i32 1 - %equal = icmp eq i32* %a, %b - ret i1 %equal -; CHECK-NEXT: ret i1 false -} - -define i1 @gep5() { -; CHECK: @gep5 - %x = alloca %gept, align 8 - %a = getelementptr inbounds %gept* %x, i64 0, i32 1 - %b = getelementptr %gept* @gepy, i64 0, i32 0 - %equal = icmp eq i32* %a, %b - ret i1 %equal -; CHECK-NEXT: ret i1 false -} - -define i1 @gep6(%gept* %x) { -; Same as @gep3 but potentially null. -; CHECK: @gep6 - %a = getelementptr %gept* %x, i64 0, i32 0 - %b = getelementptr %gept* %x, i64 0, i32 1 - %equal = icmp eq i32* %a, %b - ret i1 %equal -; CHECK-NEXT: ret i1 false -} - -define i1 @gep7(%gept* %x) { -; CHECK: @gep7 - %a = getelementptr %gept* %x, i64 0, i32 0 - %b = getelementptr %gept* @gepz, i64 0, i32 0 - %equal = icmp eq i32* %a, %b - ret i1 %equal -; CHECK: ret i1 %equal -} - define i1 @zext(i32 %x) { ; CHECK: @zext %e1 = zext i32 %x to i64 |