mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-10-26 02:22:29 +00:00
ConstantInt has some getters which return ConstantInt's or ConstantVector's of
the value splatted into every element. Extend this to getTrue and getFalse which by providing new overloads that take Types that are either i1 or <N x i1>. Use it in InstCombine to add vector support to some code, fixing PR8469! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@127116 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -465,3 +465,13 @@ define i1 @test48(i32 %X, i32 %Y, i32 %Z) {
|
||||
%C = icmp eq i32 %A, %B
|
||||
ret i1 %C
|
||||
}
|
||||
|
||||
; PR8469
|
||||
; CHECK: @test49
|
||||
; CHECK: ret <2 x i1> <i1 true, i1 true>
|
||||
define <2 x i1> @test49(<2 x i32> %tmp3) {
|
||||
entry:
|
||||
%tmp11 = and <2 x i32> %tmp3, <i32 3, i32 3>
|
||||
%cmp = icmp ult <2 x i32> %tmp11, <i32 4, i32 4>
|
||||
ret <2 x i1> %cmp
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user