1 ; RUN: llc < %s -mtriple=x86_64-apple-darwin -mcpu=knl | FileCheck %s --check-prefix=KNL
2 ; RUN: llc < %s -mtriple=x86_64-apple-darwin -mcpu=skx | FileCheck %s --check-prefix=SKX
3 ; RUN: llc < %s -mtriple=i686-apple-darwin -mcpu=knl | FileCheck %s --check-prefix=KNL
7 define <16 x i1> @test1() {
8 ret <16 x i1> zeroinitializer
21 define <16 x i1> @test2(<16 x i1>%a, <16 x i1>%b) {
22 %c = and <16 x i1>%a, %b
31 define <8 x i1> @test3(<8 x i1>%a, <8 x i1>%b) {
32 %c = and <8 x i1>%a, %b
41 define <4 x i1> @test4(<4 x i1>%a, <4 x i1>%b) {
42 %c = and <4 x i1>%a, %b
51 declare <8 x i1> @func8xi1(<8 x i1> %a)
52 define <8 x i32> @test5(<8 x i32>%a, <8 x i32>%b) {
53 %cmpRes = icmp sgt <8 x i32>%a, %b
54 %resi = call <8 x i1> @func8xi1(<8 x i1> %cmpRes)
55 %res = sext <8 x i1>%resi to <8 x i32>
59 declare <16 x i1> @func16xi1(<16 x i1> %a)
66 ; KNL: vpslld $31, %zmm
67 ; KNL: vpsrad $31, %zmm
68 define <16 x i32> @test6(<16 x i32>%a, <16 x i32>%b) {
69 %cmpRes = icmp sgt <16 x i32>%a, %b
70 %resi = call <16 x i1> @func16xi1(<16 x i1> %cmpRes)
71 %res = sext <16 x i1>%resi to <16 x i32>
75 declare <4 x i1> @func4xi1(<4 x i1> %a)
79 ; SKX: vpslld $31, %xmm
80 ; SKX: vpsrad $31, %xmm
82 define <4 x i32> @test7(<4 x i32>%a, <4 x i32>%b) {
83 %cmpRes = icmp sgt <4 x i32>%a, %b
84 %resi = call <4 x i1> @func4xi1(<4 x i1> %cmpRes)
85 %res = sext <4 x i1>%resi to <4 x i32>