mirror of
https://github.com/RPCSX/llvm.git
synced 2024-12-04 10:04:33 +00:00
Add a test that large offsets on GEPs on 32 bits targets are handled correctly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191628 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
2f101e83b2
commit
fc2599f186
@ -729,3 +729,13 @@ define i1 @non_inbounds_gep_compare(i64* %a) {
|
|||||||
ret i1 %cmp
|
ret i1 %cmp
|
||||||
; CHECK-NEXT: ret i1 true
|
; CHECK-NEXT: ret i1 true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
define i1 @non_inbounds_gep_compare2(i64* %a) {
|
||||||
|
; CHECK-LABEL: @non_inbounds_gep_compare2(
|
||||||
|
; Equality compares with non-inbounds GEPs can be folded.
|
||||||
|
%x = getelementptr i64* %a, i64 4294967297
|
||||||
|
%y = getelementptr i64* %a, i64 1
|
||||||
|
%cmp = icmp eq i64* %y, %y
|
||||||
|
ret i1 %cmp
|
||||||
|
; CHECK-NEXT: ret i1 true
|
||||||
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user