;CHECK-LABEL: test10
;CHECK: vmovd
;CHECK: vpermd %zmm
-;CHEKK: vmovdz %xmm0, %eax
+;CHECK: vmovd %xmm0, %eax
;CHECK: ret
define i32 @test10(<16 x i32> %x, i32 %ind) nounwind {
%e = extractelement <16 x i32> %x, i32 %ind
;CHECK-LABEL: test11
;CHECK: vpcmpltud
-;CKECK: kshiftlw $11
-;CKECK: kshiftrw $15
+;CHECK: kshiftlw $11
+;CHECK: kshiftrw $15
;CHECK: kortestw
;CHECK: je
;CHECK: ret
;CHECK-LABEL: test12
;CHECK: vpcmpgtq
-;CKECK: kshiftlw $15
-;CKECK: kshiftrw $15
+;CHECK: kshiftlw $15
+;CHECK: kshiftrw $15
;CHECK: kortestw
;CHECK: ret
;CHECK-LABEL: test13
;CHECK: cmpl
;CHECK: sbbl
-;CKECK: orl $65532
+;CHECK: orl $65532
;CHECK: ret
define i16 @test13(i32 %a, i32 %b) {
%cmp_res = icmp ult i32 %a, %b
ret i16 %res
}
+;CHECK-LABEL: test14
+;CHECK: vpcmpgtq
+;CHECK: kshiftlw $11
+;CHECK: kshiftrw $15
+;CHECK: kortestw
+;CHECK: ret
+
+define i64 @test14(<8 x i64>%a, <8 x i64>%b, i64 %a1, i64 %b1) {
+
+ %cmpvector_func.i = icmp slt <8 x i64> %a, %b
+ %extract24vector_func.i = extractelement <8 x i1> %cmpvector_func.i, i32 4
+ %res = select i1 %extract24vector_func.i, i64 %a1, i64 %b1
+ ret i64 %res
+}
+;CHECK-LABEL: test15
+;CHECK: kshiftlw
+;CHECK: kmovw
+;CHECK: ret
+define i16 @test15(i1 *%addr) {
+ %x = load i1 * %addr, align 128
+ %x1 = insertelement <16 x i1> undef, i1 %x, i32 10
+ %x2 = bitcast <16 x i1>%x1 to i16
+ ret i16 %x2
+}
+
+;CHECK-LABEL: test16
+;CHECK: kshiftlw
+;CHECK: kshiftrw
+;CHECK: korw
+;CHECK: ret
+define i16 @test16(i1 *%addr, i16 %a) {
+ %x = load i1 * %addr, align 128
+ %a1 = bitcast i16 %a to <16 x i1>
+ %x1 = insertelement <16 x i1> %a1, i1 %x, i32 10
+ %x2 = bitcast <16 x i1>%x1 to i16
+ ret i16 %x2
+}
+
+;CHECK-LABEL: test17
+;CHECK: kshiftlw
+;CHECK: kshiftrw
+;CHECK: korw
+;CHECK: ret
+define i8 @test17(i1 *%addr, i8 %a) {
+ %x = load i1 * %addr, align 128
+ %a1 = bitcast i8 %a to <8 x i1>
+ %x1 = insertelement <8 x i1> %a1, i1 %x, i32 10
+ %x2 = bitcast <8 x i1>%x1 to i8
+ ret i8 %x2
+}