llvm.org GIT mirror llvm / fa1c0b3
[X86][AVX512] Cleanup popcnt tests triples and attributes Avoid use of specific -mcpu git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@306988 91177308-0d34-0410-b5e6-96231b3b80d8 Simon Pilgrim 2 years ago
1 changed file(s) with 15 addition(s) and 15 deletion(s). Raw diff Collapse all Expand all
0 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
1 ; RUN: llc < %s -mtriple=x86_64-apple-darwin -mcpu=knl -mattr=+avx512f | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512F
2 ; RUN: llc < %s -mtriple=x86_64-apple-darwin -mcpu=knl -mattr=+avx512bw | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512BW
3 ; RUN: llc < %s -mtriple=x86_64-apple-darwin -mattr=+avx512vpopcntdq | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512VPOPCNTDQ
1 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512f | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512F
2 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bw | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512BW
3 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512vpopcntdq | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512VPOPCNTDQ
44
55 define <8 x i64> @testv8i64(<8 x i64> %in) nounwind {
66 ; AVX512F-LABEL: testv8i64:
7 ; AVX512F: ## BB#0:
7 ; AVX512F: # BB#0:
88 ; AVX512F-NEXT: vextracti64x4 $1, %zmm0, %ymm1
99 ; AVX512F-NEXT: vmovdqa {{.*#+}} ymm2 = [15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15]
1010 ; AVX512F-NEXT: vpand %ymm2, %ymm1, %ymm3
2727 ; AVX512F-NEXT: retq
2828 ;
2929 ; AVX512BW-LABEL: testv8i64:
30 ; AVX512BW: ## BB#0:
30 ; AVX512BW: # BB#0:
3131 ; AVX512BW-NEXT: vmovdqa64 {{.*#+}} zmm1 = [15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15]
3232 ; AVX512BW-NEXT: vpandq %zmm1, %zmm0, %zmm2
3333 ; AVX512BW-NEXT: vmovdqu8 {{.*#+}} zmm3 = [0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4]
4141 ; AVX512BW-NEXT: retq
4242 ;
4343 ; AVX512VPOPCNTDQ-LABEL: testv8i64:
44 ; AVX512VPOPCNTDQ: ## BB#0:
44 ; AVX512VPOPCNTDQ: # BB#0:
4545 ; AVX512VPOPCNTDQ-NEXT: vpopcntq %zmm0, %zmm0
4646 ; AVX512VPOPCNTDQ-NEXT: retq
4747 %out = call <8 x i64> @llvm.ctpop.v8i64(<8 x i64> %in)
5050
5151 define <16 x i32> @testv16i32(<16 x i32> %in) nounwind {
5252 ; AVX512F-LABEL: testv16i32:
53 ; AVX512F: ## BB#0:
53 ; AVX512F: # BB#0:
5454 ; AVX512F-NEXT: vextracti64x4 $1, %zmm0, %ymm1
5555 ; AVX512F-NEXT: vmovdqa {{.*#+}} ymm2 = [15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15]
5656 ; AVX512F-NEXT: vpand %ymm2, %ymm1, %ymm3
8181 ; AVX512F-NEXT: retq
8282 ;
8383 ; AVX512BW-LABEL: testv16i32:
84 ; AVX512BW: ## BB#0:
84 ; AVX512BW: # BB#0:
8585 ; AVX512BW-NEXT: vmovdqa64 {{.*#+}} zmm1 = [15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15]
8686 ; AVX512BW-NEXT: vpandq %zmm1, %zmm0, %zmm2
8787 ; AVX512BW-NEXT: vmovdqu8 {{.*#+}} zmm3 = [0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4]
9999 ; AVX512BW-NEXT: retq
100100 ;
101101 ; AVX512VPOPCNTDQ-LABEL: testv16i32:
102 ; AVX512VPOPCNTDQ: ## BB#0:
102 ; AVX512VPOPCNTDQ: # BB#0:
103103 ; AVX512VPOPCNTDQ-NEXT: vpopcntd %zmm0, %zmm0
104104 ; AVX512VPOPCNTDQ-NEXT: retq
105105 %out = call <16 x i32> @llvm.ctpop.v16i32(<16 x i32> %in)
108108
109109 define <32 x i16> @testv32i16(<32 x i16> %in) nounwind {
110110 ; AVX512F-LABEL: testv32i16:
111 ; AVX512F: ## BB#0:
111 ; AVX512F: # BB#0:
112112 ; AVX512F-NEXT: vmovdqa {{.*#+}} ymm2 = [15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15]
113113 ; AVX512F-NEXT: vpand %ymm2, %ymm0, %ymm3
114114 ; AVX512F-NEXT: vmovdqa {{.*#+}} ymm4 = [0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4]
132132 ; AVX512F-NEXT: retq
133133 ;
134134 ; AVX512BW-LABEL: testv32i16:
135 ; AVX512BW: ## BB#0:
135 ; AVX512BW: # BB#0:
136136 ; AVX512BW-NEXT: vmovdqa64 {{.*#+}} zmm1 = [15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15]
137137 ; AVX512BW-NEXT: vpandq %zmm1, %zmm0, %zmm2
138138 ; AVX512BW-NEXT: vmovdqu8 {{.*#+}} zmm3 = [0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4]
147147 ; AVX512BW-NEXT: retq
148148 ;
149149 ; AVX512VPOPCNTDQ-LABEL: testv32i16:
150 ; AVX512VPOPCNTDQ: ## BB#0:
150 ; AVX512VPOPCNTDQ: # BB#0:
151151 ; AVX512VPOPCNTDQ-NEXT: vmovdqa {{.*#+}} ymm2 = [15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15]
152152 ; AVX512VPOPCNTDQ-NEXT: vpand %ymm2, %ymm0, %ymm3
153153 ; AVX512VPOPCNTDQ-NEXT: vmovdqa {{.*#+}} ymm4 = [0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4]
175175
176176 define <64 x i8> @testv64i8(<64 x i8> %in) nounwind {
177177 ; AVX512F-LABEL: testv64i8:
178 ; AVX512F: ## BB#0:
178 ; AVX512F: # BB#0:
179179 ; AVX512F-NEXT: vmovdqa {{.*#+}} ymm2 = [15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15]
180180 ; AVX512F-NEXT: vpand %ymm2, %ymm0, %ymm3
181181 ; AVX512F-NEXT: vmovdqa {{.*#+}} ymm4 = [0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4]
193193 ; AVX512F-NEXT: retq
194194 ;
195195 ; AVX512BW-LABEL: testv64i8:
196 ; AVX512BW: ## BB#0:
196 ; AVX512BW: # BB#0:
197197 ; AVX512BW-NEXT: vmovdqa64 {{.*#+}} zmm1 = [15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15]
198198 ; AVX512BW-NEXT: vpandq %zmm1, %zmm0, %zmm2
199199 ; AVX512BW-NEXT: vmovdqu8 {{.*#+}} zmm3 = [0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4]
205205 ; AVX512BW-NEXT: retq
206206 ;
207207 ; AVX512VPOPCNTDQ-LABEL: testv64i8:
208 ; AVX512VPOPCNTDQ: ## BB#0:
208 ; AVX512VPOPCNTDQ: # BB#0:
209209 ; AVX512VPOPCNTDQ-NEXT: vmovdqa {{.*#+}} ymm2 = [15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15,15]
210210 ; AVX512VPOPCNTDQ-NEXT: vpand %ymm2, %ymm0, %ymm3
211211 ; AVX512VPOPCNTDQ-NEXT: vmovdqa {{.*#+}} ymm4 = [0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4,0,1,1,2,1,2,2,3,1,2,2,3,2,3,3,4]