llvm.org GIT mirror llvm / 09a18aa
[x86][icelake]BITALG vpopcnt{b,w} Differential Revision: https://reviews.llvm.org/D40213 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@318748 91177308-0d34-0410-b5e6-96231b3b80d8 Coby Tayree 2 years ago
15 changed file(s) with 544 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
12681268 // Enable Vector Neural Network Instructions
12691269 Features["avx512vnni"] = HasLeaf7 && ((ECX >> 11) & 1) && HasAVX512Save;
12701270
1271 // Enable Bit Algorithms
1272 Features["avx512bitalg"] = HasLeaf7 && ((ECX >> 12) & 1) && HasAVX512Save;
1273
12711274 bool HasLeafD = MaxLevel >= 0xd &&
12721275 !getX86CpuIDAndInfoEx(0xd, 0x1, &EAX, &EBX, &ECX, &EDX);
12731276
162162 def FeatureVNNI : SubtargetFeature<"avx512vnni", "HasVNNI", "true",
163163 "Enable AVX-512 Vector Neural Network Instructions",
164164 [FeatureAVX512]>;
165 def FeatureBITALG : SubtargetFeature<"avx512bitalg", "HasBITALG", "true",
166 "Enable AVX-512 Bit Algorithms",
167 [FeatureBWI]>;
165168 def FeaturePCLMUL : SubtargetFeature<"pclmul", "HasPCLMUL", "true",
166169 "Enable packed carry-less multiplication instructions",
167170 [FeatureSSE2]>;
15541554 setOperationAction(ISD::UMIN, VT, Legal);
15551555 }
15561556 }
1557
1558 if (Subtarget.hasBITALG())
1559 for (auto VT : { MVT::v64i8, MVT::v32i16, MVT::v32i8,
1560 MVT::v16i16, MVT::v16i8, MVT::v8i16 })
1561 setOperationAction(ISD::CTPOP, VT, Legal);
15571562
15581563 // We want to custom lower some of our intrinsics.
15591564 setOperationAction(ISD::INTRINSIC_WO_CHAIN, MVT::Other, Custom);
1020310203 defm VPDPWSSD : VNNI_common<0x52, "vpdpwssd", X86Vpdpwssd>;
1020410204 defm VPDPWSSDS : VNNI_common<0x53, "vpdpwssds", X86Vpdpwssds>;
1020510205
10206 //===----------------------------------------------------------------------===//
10207 // Bit Algorithms
10208 //===----------------------------------------------------------------------===//
10209
10210 defm VPOPCNTB : avx512_unary_rm_vl<0x54, "vpopcntb", ctpop,
10211 avx512vl_i8_info, HasBITALG>,
10212 avx512_unary_lowering;
10213 defm VPOPCNTW : avx512_unary_rm_vl<0x54, "vpopcntw", ctpop,
10214 avx512vl_i16_info, HasBITALG>,
10215 avx512_unary_lowering, VEX_W;
10216
833833 def PKU : Predicate<"Subtarget->hasPKU()">;
834834 def HasVNNI : Predicate<"Subtarget->hasVNNI()">;
835835
836 def HasBITALG : Predicate<"Subtarget->hasBITALG()">;
836837 def HasPOPCNT : Predicate<"Subtarget->hasPOPCNT()">;
837838 def HasAES : Predicate<"Subtarget->hasAES()">;
838839 def HasVAES : Predicate<"Subtarget->hasVAES()">;
325325 HasADX = false;
326326 HasPKU = false;
327327 HasVNNI = false;
328 HasBITALG = false;
328329 HasSHA = false;
329330 HasPRFCHW = false;
330331 HasRDSEED = false;
305305
306306 /// Processor has AVX-512 Vector Neural Network Instructions
307307 bool HasVNNI;
308
309 /// Processor has AVX-512 Bit Algorithms instructions
310 bool HasBITALG;
308311
309312 /// Processor supports MPX - Memory Protection Extensions
310313 bool HasMPX;
533536 bool hasVLX() const { return HasVLX; }
534537 bool hasPKU() const { return HasPKU; }
535538 bool hasVNNI() const { return HasVNNI; }
539 bool hasBITALG() const { return HasBITALG; }
536540 bool hasMPX() const { return HasMPX; }
537541 bool hasCLFLUSHOPT() const { return HasCLFLUSHOPT; }
538542 bool hasCLWB() const { return HasCLWB; }
55 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX1
66 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx2 | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX2
77 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512vpopcntdq | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX512VPOPCNTDQ
8 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bitalg | FileCheck %s --check-prefix=ALL --check-prefix=BITALG_NOVLX
9 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bitalg,+avx512vl | FileCheck %s --check-prefix=ALL --check-prefix=BITALG
810
911 define <2 x i64> @testv2i64(<2 x i64> %in) nounwind {
1012 ; SSE2-LABEL: testv2i64:
380382 ; AVX512VPOPCNTDQ-NEXT: vpmovqw %zmm0, %xmm0
381383 ; AVX512VPOPCNTDQ-NEXT: vzeroupper
382384 ; AVX512VPOPCNTDQ-NEXT: retq
385 ;
386 ; BITALG_NOVLX-LABEL: testv8i16:
387 ; BITALG_NOVLX: # BB#0:
388 ; BITALG_NOVLX-NEXT: # kill: %XMM0 %XMM0 %ZMM0
389 ; BITALG_NOVLX-NEXT: vpopcntw %zmm0, %zmm0
390 ; BITALG_NOVLX-NEXT: # kill: %XMM0 %XMM0 %ZMM0
391 ; BITALG_NOVLX-NEXT: vzeroupper
392 ; BITALG_NOVLX-NEXT: retq
393 ;
394 ; BITALG-LABEL: testv8i16:
395 ; BITALG: # BB#0:
396 ; BITALG-NEXT: vpopcntw %xmm0, %xmm0
397 ; BITALG-NEXT: retq
383398 %out = call <8 x i16> @llvm.ctpop.v8i16(<8 x i16> %in)
384399 ret <8 x i16> %out
385400 }
484499 ; AVX512VPOPCNTDQ-NEXT: vpmovdb %zmm0, %xmm0
485500 ; AVX512VPOPCNTDQ-NEXT: vzeroupper
486501 ; AVX512VPOPCNTDQ-NEXT: retq
502 ;
503 ; BITALG_NOVLX-LABEL: testv16i8:
504 ; BITALG_NOVLX: # BB#0:
505 ; BITALG_NOVLX-NEXT: # kill: %XMM0 %XMM0 %ZMM0
506 ; BITALG_NOVLX-NEXT: vpopcntb %zmm0, %zmm0
507 ; BITALG_NOVLX-NEXT: # kill: %XMM0 %XMM0 %ZMM0
508 ; BITALG_NOVLX-NEXT: vzeroupper
509 ; BITALG_NOVLX-NEXT: retq
510 ;
511 ; BITALG-LABEL: testv16i8:
512 ; BITALG: # BB#0:
513 ; BITALG-NEXT: vpopcntb %xmm0, %xmm0
514 ; BITALG-NEXT: retq
487515 %out = call <16 x i8> @llvm.ctpop.v16i8(<16 x i8> %in)
488516 ret <16 x i8> %out
489517 }
11 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX1
22 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx2 | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX2
33 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512vpopcntdq | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX512VPOPCNTDQ
4 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bitalg | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=BITALG_NOVLX
5 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bitalg,+avx512vl | FileCheck %s --check-prefix=ALL --check-prefix=BITALG
46
57 define <4 x i64> @testv4i64(<4 x i64> %in) nounwind {
68 ; AVX1-LABEL: testv4i64:
158160 ; AVX512VPOPCNTDQ-NEXT: vpopcntd %zmm0, %zmm0
159161 ; AVX512VPOPCNTDQ-NEXT: vpmovdw %zmm0, %ymm0
160162 ; AVX512VPOPCNTDQ-NEXT: retq
163 ;
164 ; BITALG_NOVLX-LABEL: testv16i16:
165 ; BITALG_NOVLX: # BB#0:
166 ; BITALG_NOVLX-NEXT: # kill: %YMM0 %YMM0 %ZMM0
167 ; BITALG_NOVLX-NEXT: vpopcntw %zmm0, %zmm0
168 ; BITALG_NOVLX-NEXT: # kill: %YMM0 %YMM0 %ZMM0
169 ; BITALG_NOVLX-NEXT: retq
170 ;
171 ; BITALG-LABEL: testv16i16:
172 ; BITALG: # BB#0:
173 ; BITALG-NEXT: vpopcntw %ymm0, %ymm0
174 ; BITALG-NEXT: retq
161175 %out = call <16 x i16> @llvm.ctpop.v16i16(<16 x i16> %in)
162176 ret <16 x i16> %out
163177 }
206220 ; AVX512VPOPCNTDQ-NEXT: vpshufb %ymm0, %ymm3, %ymm0
207221 ; AVX512VPOPCNTDQ-NEXT: vpaddb %ymm2, %ymm0, %ymm0
208222 ; AVX512VPOPCNTDQ-NEXT: retq
223 ;
224 ; BITALG_NOVLX-LABEL: testv32i8:
225 ; BITALG_NOVLX: # BB#0:
226 ; BITALG_NOVLX-NEXT: # kill: %YMM0 %YMM0 %ZMM0
227 ; BITALG_NOVLX-NEXT: vpopcntb %zmm0, %zmm0
228 ; BITALG_NOVLX-NEXT: # kill: %YMM0 %YMM0 %ZMM0
229 ; BITALG_NOVLX-NEXT: retq
230 ;
231 ; BITALG-LABEL: testv32i8:
232 ; BITALG: # BB#0:
233 ; BITALG-NEXT: vpopcntb %ymm0, %ymm0
234 ; BITALG-NEXT: retq
209235 %out = call <32 x i8> @llvm.ctpop.v32i8(<32 x i8> %in)
210236 ret <32 x i8> %out
211237 }
22 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bw | FileCheck %s --check-prefix=AVX512 --check-prefix=AVX512BW
33 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512vpopcntdq | FileCheck %s --check-prefix=AVX512 --check-prefix=AVX512VPOPCNTDQ --check-prefix=AVX512VPOPCNTDQ-NOBW
44 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512vpopcntdq,+avx512bw | FileCheck %s --check-prefix=AVX512 --check-prefix=AVX512VPOPCNTDQ --check-prefix=AVX512VPOPCNTDQ-BW
5 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bitalg | FileCheck %s --check-prefix=AVX512 --check-prefix=BITALG
56
67 define <8 x i64> @testv8i64(<8 x i64> %in) nounwind {
78 ; AVX512F-LABEL: testv8i64:
171172 ; AVX512VPOPCNTDQ-BW-NEXT: vpaddb %zmm0, %zmm1, %zmm0
172173 ; AVX512VPOPCNTDQ-BW-NEXT: vpsrlw $8, %zmm0, %zmm0
173174 ; AVX512VPOPCNTDQ-BW-NEXT: retq
175 ;
176 ; BITALG-LABEL: testv32i16:
177 ; BITALG: # BB#0:
178 ; BITALG-NEXT: vpopcntw %zmm0, %zmm0
179 ; BITALG-NEXT: retq
174180 %out = call <32 x i16> @llvm.ctpop.v32i16(<32 x i16> %in)
175181 ret <32 x i16> %out
176182 }
235241 ; AVX512VPOPCNTDQ-BW-NEXT: vpshufb %zmm0, %zmm3, %zmm0
236242 ; AVX512VPOPCNTDQ-BW-NEXT: vpaddb %zmm2, %zmm0, %zmm0
237243 ; AVX512VPOPCNTDQ-BW-NEXT: retq
244 ;
245 ; BITALG-LABEL: testv64i8:
246 ; BITALG: # BB#0:
247 ; BITALG-NEXT: vpopcntb %zmm0, %zmm0
248 ; BITALG-NEXT: retq
238249 %out = call <64 x i8> @llvm.ctpop.v64i8(<64 x i8> %in)
239250 ret <64 x i8> %out
240251 }
77 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512cd,+avx512vl | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX512CDVL
88 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512cd,-avx512vl | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX512CD
99 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512vpopcntdq | FileCheck %s --check-prefix=ALL --check-prefix=AVX512VPOPCNTDQ
10 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bitalg | FileCheck %s --check-prefix=ALL --check-prefix=BITALG_NOVLX
11 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bitalg,+avx512vl | FileCheck %s --check-prefix=ALL --check-prefix=BITALG
1012 ;
1113 ; Just one 32-bit run to make sure we do reasonable things for i64 tzcnt.
1214 ; RUN: llc < %s -mtriple=i686-unknown-unknown -mattr=+sse4.1 | FileCheck %s --check-prefix=ALL --check-prefix=X32-SSE --check-prefix=X32-SSE41
933935 ; AVX512VPOPCNTDQ-NEXT: vzeroupper
934936 ; AVX512VPOPCNTDQ-NEXT: retq
935937 ;
938 ; BITALG_NOVLX-LABEL: testv8i16:
939 ; BITALG_NOVLX: # BB#0:
940 ; BITALG_NOVLX-NEXT: vpxor %xmm1, %xmm1, %xmm1
941 ; BITALG_NOVLX-NEXT: vpsubw %xmm0, %xmm1, %xmm1
942 ; BITALG_NOVLX-NEXT: vpand %xmm1, %xmm0, %xmm0
943 ; BITALG_NOVLX-NEXT: vpcmpeqd %xmm1, %xmm1, %xmm1
944 ; BITALG_NOVLX-NEXT: vpaddw %xmm1, %xmm0, %xmm0
945 ; BITALG_NOVLX-NEXT: vpopcntw %zmm0, %zmm0
946 ; BITALG_NOVLX-NEXT: # kill: %XMM0 %XMM0 %ZMM0
947 ; BITALG_NOVLX-NEXT: vzeroupper
948 ; BITALG_NOVLX-NEXT: retq
949 ;
950 ; BITALG-LABEL: testv8i16:
951 ; BITALG: # BB#0:
952 ; BITALG-NEXT: vpxor %xmm1, %xmm1, %xmm1
953 ; BITALG-NEXT: vpsubw %xmm0, %xmm1, %xmm1
954 ; BITALG-NEXT: vpand %xmm1, %xmm0, %xmm0
955 ; BITALG-NEXT: vpcmpeqd %xmm1, %xmm1, %xmm1
956 ; BITALG-NEXT: vpaddw %xmm1, %xmm0, %xmm0
957 ; BITALG-NEXT: vpopcntw %xmm0, %xmm0
958 ; BITALG-NEXT: retq
959 ;
936960 ; X32-SSE-LABEL: testv8i16:
937961 ; X32-SSE: # BB#0:
938962 ; X32-SSE-NEXT: pxor %xmm1, %xmm1
12341258 ; AVX512VPOPCNTDQ-NEXT: vzeroupper
12351259 ; AVX512VPOPCNTDQ-NEXT: retq
12361260 ;
1261 ; BITALG_NOVLX-LABEL: testv16i8:
1262 ; BITALG_NOVLX: # BB#0:
1263 ; BITALG_NOVLX-NEXT: vpxor %xmm1, %xmm1, %xmm1
1264 ; BITALG_NOVLX-NEXT: vpsubb %xmm0, %xmm1, %xmm1
1265 ; BITALG_NOVLX-NEXT: vpand %xmm1, %xmm0, %xmm0
1266 ; BITALG_NOVLX-NEXT: vpcmpeqd %xmm1, %xmm1, %xmm1
1267 ; BITALG_NOVLX-NEXT: vpaddb %xmm1, %xmm0, %xmm0
1268 ; BITALG_NOVLX-NEXT: vpopcntb %zmm0, %zmm0
1269 ; BITALG_NOVLX-NEXT: # kill: %XMM0 %XMM0 %ZMM0
1270 ; BITALG_NOVLX-NEXT: vzeroupper
1271 ; BITALG_NOVLX-NEXT: retq
1272 ;
1273 ; BITALG-LABEL: testv16i8:
1274 ; BITALG: # BB#0:
1275 ; BITALG-NEXT: vpxor %xmm1, %xmm1, %xmm1
1276 ; BITALG-NEXT: vpsubb %xmm0, %xmm1, %xmm1
1277 ; BITALG-NEXT: vpand %xmm1, %xmm0, %xmm0
1278 ; BITALG-NEXT: vpcmpeqd %xmm1, %xmm1, %xmm1
1279 ; BITALG-NEXT: vpaddb %xmm1, %xmm0, %xmm0
1280 ; BITALG-NEXT: vpopcntb %xmm0, %xmm0
1281 ; BITALG-NEXT: retq
1282 ;
12371283 ; X32-SSE-LABEL: testv16i8:
12381284 ; X32-SSE: # BB#0:
12391285 ; X32-SSE-NEXT: pxor %xmm1, %xmm1
33 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512cd,+avx512vl | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX512CDVL
44 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512cd,-avx512vl | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX512CD
55 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512vpopcntdq | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX512VPOPCNTDQ
6 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bitalg | FileCheck %s --check-prefix=ALL --check-prefix=BITALG_NOVLX
7 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bitalg,+avx512vl | FileCheck %s --check-prefix=ALL --check-prefix=BITALG
68 ;
79 ; Just one 32-bit run to make sure we do reasonable things for i64 tzcnt.
810 ; RUN: llc < %s -mtriple=i686-unknown-unknown -mattr=+avx2 | FileCheck %s --check-prefix=ALL --check-prefix=X32-AVX --check-prefix=X32-AVX2
588590 ; AVX512VPOPCNTDQ-NEXT: vpmovdw %zmm0, %ymm0
589591 ; AVX512VPOPCNTDQ-NEXT: retq
590592 ;
593 ; BITALG_NOVLX-LABEL: testv16i16:
594 ; BITALG_NOVLX: # BB#0:
595 ; BITALG_NOVLX-NEXT: vpxor %xmm1, %xmm1, %xmm1
596 ; BITALG_NOVLX-NEXT: vpsubw %ymm0, %ymm1, %ymm1
597 ; BITALG_NOVLX-NEXT: vpand %ymm1, %ymm0, %ymm0
598 ; BITALG_NOVLX-NEXT: vpcmpeqd %ymm1, %ymm1, %ymm1
599 ; BITALG_NOVLX-NEXT: vpaddw %ymm1, %ymm0, %ymm0
600 ; BITALG_NOVLX-NEXT: vpopcntw %zmm0, %zmm0
601 ; BITALG_NOVLX-NEXT: # kill: %YMM0 %YMM0 %ZMM0
602 ; BITALG_NOVLX-NEXT: retq
603 ;
604 ; BITALG-LABEL: testv16i16:
605 ; BITALG: # BB#0:
606 ; BITALG-NEXT: vpxor %xmm1, %xmm1, %xmm1
607 ; BITALG-NEXT: vpsubw %ymm0, %ymm1, %ymm1
608 ; BITALG-NEXT: vpand %ymm1, %ymm0, %ymm0
609 ; BITALG-NEXT: vpcmpeqd %ymm1, %ymm1, %ymm1
610 ; BITALG-NEXT: vpaddw %ymm1, %ymm0, %ymm0
611 ; BITALG-NEXT: vpopcntw %ymm0, %ymm0
612 ; BITALG-NEXT: retq
613 ;
591614 ; X32-AVX-LABEL: testv16i16:
592615 ; X32-AVX: # BB#0:
593616 ; X32-AVX-NEXT: vpxor %xmm1, %xmm1, %xmm1
838861 ; AVX512VPOPCNTDQ-NEXT: vpaddb %ymm2, %ymm0, %ymm0
839862 ; AVX512VPOPCNTDQ-NEXT: retq
840863 ;
864 ; BITALG_NOVLX-LABEL: testv32i8:
865 ; BITALG_NOVLX: # BB#0:
866 ; BITALG_NOVLX-NEXT: vpxor %xmm1, %xmm1, %xmm1
867 ; BITALG_NOVLX-NEXT: vpsubb %ymm0, %ymm1, %ymm1
868 ; BITALG_NOVLX-NEXT: vpand %ymm1, %ymm0, %ymm0
869 ; BITALG_NOVLX-NEXT: vpcmpeqd %ymm1, %ymm1, %ymm1
870 ; BITALG_NOVLX-NEXT: vpaddb %ymm1, %ymm0, %ymm0
871 ; BITALG_NOVLX-NEXT: vpopcntb %zmm0, %zmm0
872 ; BITALG_NOVLX-NEXT: # kill: %YMM0 %YMM0 %ZMM0
873 ; BITALG_NOVLX-NEXT: retq
874 ;
875 ; BITALG-LABEL: testv32i8:
876 ; BITALG: # BB#0:
877 ; BITALG-NEXT: vpxor %xmm1, %xmm1, %xmm1
878 ; BITALG-NEXT: vpsubb %ymm0, %ymm1, %ymm1
879 ; BITALG-NEXT: vpand %ymm1, %ymm0, %ymm0
880 ; BITALG-NEXT: vpcmpeqd %ymm1, %ymm1, %ymm1
881 ; BITALG-NEXT: vpaddb %ymm1, %ymm0, %ymm0
882 ; BITALG-NEXT: vpopcntb %ymm0, %ymm0
883 ; BITALG-NEXT: retq
884 ;
841885 ; X32-AVX-LABEL: testv32i8:
842886 ; X32-AVX: # BB#0:
843887 ; X32-AVX-NEXT: vpxor %xmm1, %xmm1, %xmm1
22 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512f,+avx512cd,+avx512bw | FileCheck %s --check-prefix=ALL --check-prefix=AVX512CDBW
33 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512f,+avx512bw | FileCheck %s --check-prefix=ALL --check-prefix=AVX512BW
44 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512vpopcntdq | FileCheck %s --check-prefix=ALL --check-prefix=AVX512VPOPCNTDQ
5 ; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bitalg | FileCheck %s --check-prefix=ALL --check-prefix=BITALG
56
67 define <8 x i64> @testv8i64(<8 x i64> %in) nounwind {
78 ; AVX512CD-LABEL: testv8i64:
373374 ; AVX512VPOPCNTDQ-NEXT: vpopcntd %zmm1, %zmm1
374375 ; AVX512VPOPCNTDQ-NEXT: vpmovdw %zmm1, %ymm1
375376 ; AVX512VPOPCNTDQ-NEXT: retq
377 ;
378 ; BITALG-LABEL: testv32i16:
379 ; BITALG: # BB#0:
380 ; BITALG-NEXT: vpxor %xmm1, %xmm1, %xmm1
381 ; BITALG-NEXT: vpsubw %zmm0, %zmm1, %zmm1
382 ; BITALG-NEXT: vpandq %zmm1, %zmm0, %zmm0
383 ; BITALG-NEXT: vpternlogd $255, %zmm1, %zmm1, %zmm1
384 ; BITALG-NEXT: vpaddw %zmm1, %zmm0, %zmm0
385 ; BITALG-NEXT: vpopcntw %zmm0, %zmm0
386 ; BITALG-NEXT: retq
376387 %out = call <32 x i16> @llvm.cttz.v32i16(<32 x i16> %in, i1 0)
377388 ret <32 x i16> %out
378389 }
557568 ; AVX512VPOPCNTDQ-NEXT: vpshufb %ymm1, %ymm6, %ymm1
558569 ; AVX512VPOPCNTDQ-NEXT: vpaddb %ymm2, %ymm1, %ymm1
559570 ; AVX512VPOPCNTDQ-NEXT: retq
571 ;
572 ; BITALG-LABEL: testv64i8:
573 ; BITALG: # BB#0:
574 ; BITALG-NEXT: vpxor %xmm1, %xmm1, %xmm1
575 ; BITALG-NEXT: vpsubb %zmm0, %zmm1, %zmm1
576 ; BITALG-NEXT: vpandq %zmm1, %zmm0, %zmm0
577 ; BITALG-NEXT: vpternlogd $255, %zmm1, %zmm1, %zmm1
578 ; BITALG-NEXT: vpaddb %zmm1, %zmm0, %zmm0
579 ; BITALG-NEXT: vpopcntb %zmm0, %zmm0
580 ; BITALG-NEXT: retq
560581 %out = call <64 x i8> @llvm.cttz.v64i8(<64 x i8> %in, i1 0)
561582 ret <64 x i8> %out
562583 }
0 // RUN: llvm-mc -triple x86_64-unknown-unknown -mcpu=knl -mattr=+avx512bitalg --show-encoding < %s | FileCheck %s
1
2 // CHECK: vpopcntb %zmm23, %zmm21
3 // CHECK: encoding: [0x62,0xa2,0x7d,0x48,0x54,0xef]
4 vpopcntb %zmm23, %zmm21
5
6 // CHECK: vpopcntw %zmm23, %zmm21
7 // CHECK: encoding: [0x62,0xa2,0xfd,0x48,0x54,0xef]
8 vpopcntw %zmm23, %zmm21
9
10 // CHECK: vpopcntb %zmm3, %zmm1 {%k2}
11 // CHECK: encoding: [0x62,0xf2,0x7d,0x4a,0x54,0xcb]
12 vpopcntb %zmm3, %zmm1 {%k2}
13
14 // CHECK: vpopcntw %zmm3, %zmm1 {%k2}
15 // CHECK: encoding: [0x62,0xf2,0xfd,0x4a,0x54,0xcb]
16 vpopcntw %zmm3, %zmm1 {%k2}
17
18 // CHECK: vpopcntb (%rcx), %zmm1
19 // CHECK: encoding: [0x62,0xf2,0x7d,0x48,0x54,0x09]
20 vpopcntb (%rcx), %zmm1
21
22 // CHECK: vpopcntb -256(%rsp), %zmm1
23 // CHECK: encoding: [0x62,0xf2,0x7d,0x48,0x54,0x4c,0x24,0xfc]
24 vpopcntb -256(%rsp), %zmm1
25
26 // CHECK: vpopcntb 256(%rsp), %zmm1
27 // CHECK: encoding: [0x62,0xf2,0x7d,0x48,0x54,0x4c,0x24,0x04]
28 vpopcntb 256(%rsp), %zmm1
29
30 // CHECK: vpopcntb 268435456(%rcx,%r14,8), %zmm1
31 // CHECK: encoding: [0x62,0xb2,0x7d,0x48,0x54,0x8c,0xf1,0x00,0x00,0x00,0x10]
32 vpopcntb 268435456(%rcx,%r14,8), %zmm1
33
34 // CHECK: vpopcntb -536870912(%rcx,%r14,8), %zmm1
35 // CHECK: encoding: [0x62,0xb2,0x7d,0x48,0x54,0x8c,0xf1,0x00,0x00,0x00,0xe0]
36 vpopcntb -536870912(%rcx,%r14,8), %zmm1
37
38 // CHECK: vpopcntb -536870910(%rcx,%r14,8), %zmm1
39 // CHECK: encoding: [0x62,0xb2,0x7d,0x48,0x54,0x8c,0xf1,0x02,0x00,0x00,0xe0]
40 vpopcntb -536870910(%rcx,%r14,8), %zmm1
41
42 // CHECK: vpopcntw (%rcx), %zmm1
43 // CHECK: encoding: [0x62,0xf2,0xfd,0x48,0x54,0x09]
44 vpopcntw (%rcx), %zmm1
45
46 // CHECK: vpopcntw -256(%rsp), %zmm1
47 // CHECK: encoding: [0x62,0xf2,0xfd,0x48,0x54,0x4c,0x24,0xfc]
48 vpopcntw -256(%rsp), %zmm1
49
50 // CHECK: vpopcntw 256(%rsp), %zmm1
51 // CHECK: encoding: [0x62,0xf2,0xfd,0x48,0x54,0x4c,0x24,0x04]
52 vpopcntw 256(%rsp), %zmm1
53
54 // CHECK: vpopcntw 268435456(%rcx,%r14,8), %zmm1
55 // CHECK: encoding: [0x62,0xb2,0xfd,0x48,0x54,0x8c,0xf1,0x00,0x00,0x00,0x10]
56 vpopcntw 268435456(%rcx,%r14,8), %zmm1
57
58 // CHECK: vpopcntw -536870912(%rcx,%r14,8), %zmm1
59 // CHECK: encoding: [0x62,0xb2,0xfd,0x48,0x54,0x8c,0xf1,0x00,0x00,0x00,0xe0]
60 vpopcntw -536870912(%rcx,%r14,8), %zmm1
61
62 // CHECK: vpopcntw -536870910(%rcx,%r14,8), %zmm1
63 // CHECK: encoding: [0x62,0xb2,0xfd,0x48,0x54,0x8c,0xf1,0x02,0x00,0x00,0xe0]
64 vpopcntw -536870910(%rcx,%r14,8), %zmm1
65
66 // CHECK: vpopcntb (%rcx), %zmm21 {%k2}
67 // CHECK: encoding: [0x62,0xe2,0x7d,0x4a,0x54,0x29]
68 vpopcntb (%rcx), %zmm21 {%k2}
69
70 // CHECK: vpopcntb -256(%rsp), %zmm21 {%k2}
71 // CHECK: encoding: [0x62,0xe2,0x7d,0x4a,0x54,0x6c,0x24,0xfc]
72 vpopcntb -256(%rsp), %zmm21 {%k2}
73
74 // CHECK: vpopcntb 256(%rsp), %zmm21 {%k2}
75 // CHECK: encoding: [0x62,0xe2,0x7d,0x4a,0x54,0x6c,0x24,0x04]
76 vpopcntb 256(%rsp), %zmm21 {%k2}
77
78 // CHECK: vpopcntb 268435456(%rcx,%r14,8), %zmm21 {%k2}
79 // CHECK: encoding: [0x62,0xa2,0x7d,0x4a,0x54,0xac,0xf1,0x00,0x00,0x00,0x10]
80 vpopcntb 268435456(%rcx,%r14,8), %zmm21 {%k2}
81
82 // CHECK: vpopcntb -536870912(%rcx,%r14,8), %zmm21 {%k2}
83 // CHECK: encoding: [0x62,0xa2,0x7d,0x4a,0x54,0xac,0xf1,0x00,0x00,0x00,0xe0]
84 vpopcntb -536870912(%rcx,%r14,8), %zmm21 {%k2}
85
86 // CHECK: vpopcntb -536870910(%rcx,%r14,8), %zmm21 {%k2}
87 // CHECK: encoding: [0x62,0xa2,0x7d,0x4a,0x54,0xac,0xf1,0x02,0x00,0x00,0xe0]
88 vpopcntb -536870910(%rcx,%r14,8), %zmm21 {%k2}
89
90 // CHECK: vpopcntw (%rcx), %zmm21 {%k2}
91 // CHECK: encoding: [0x62,0xe2,0xfd,0x4a,0x54,0x29]
92 vpopcntw (%rcx), %zmm21 {%k2}
93
94 // CHECK: vpopcntw -256(%rsp), %zmm21 {%k2}
95 // CHECK: encoding: [0x62,0xe2,0xfd,0x4a,0x54,0x6c,0x24,0xfc]
96 vpopcntw -256(%rsp), %zmm21 {%k2}
97
98 // CHECK: vpopcntw 256(%rsp), %zmm21 {%k2}
99 // CHECK: encoding: [0x62,0xe2,0xfd,0x4a,0x54,0x6c,0x24,0x04]
100 vpopcntw 256(%rsp), %zmm21 {%k2}
101
102 // CHECK: vpopcntw 268435456(%rcx,%r14,8), %zmm21 {%k2}
103 // CHECK: encoding: [0x62,0xa2,0xfd,0x4a,0x54,0xac,0xf1,0x00,0x00,0x00,0x10]
104 vpopcntw 268435456(%rcx,%r14,8), %zmm21 {%k2}
105
106 // CHECK: vpopcntw -536870912(%rcx,%r14,8), %zmm21 {%k2}
107 // CHECK: encoding: [0x62,0xa2,0xfd,0x4a,0x54,0xac,0xf1,0x00,0x00,0x00,0xe0]
108 vpopcntw -536870912(%rcx,%r14,8), %zmm21 {%k2}
109
110 // CHECK: vpopcntw -536870910(%rcx,%r14,8), %zmm21 {%k2}
111 // CHECK: encoding: [0x62,0xa2,0xfd,0x4a,0x54,0xac,0xf1,0x02,0x00,0x00,0xe0]
112 vpopcntw -536870910(%rcx,%r14,8), %zmm21 {%k2}
113
0 // RUN: llvm-mc -triple x86_64-unknown-unknown -mcpu=knl -mattr=+avx512vl,+avx512bitalg --show-encoding < %s | FileCheck %s
1
2 // CHECK: vpopcntb %xmm23, %xmm21
3 // CHECK: encoding: [0x62,0xa2,0x7d,0x08,0x54,0xef]
4 vpopcntb %xmm23, %xmm21
5
6 // CHECK: vpopcntw %xmm23, %xmm21
7 // CHECK: encoding: [0x62,0xa2,0xfd,0x08,0x54,0xef]
8 vpopcntw %xmm23, %xmm21
9
10 // CHECK: vpopcntb %xmm3, %xmm1 {%k2}
11 // CHECK: encoding: [0x62,0xf2,0x7d,0x0a,0x54,0xcb]
12 vpopcntb %xmm3, %xmm1 {%k2}
13
14 // CHECK: vpopcntw %xmm3, %xmm1 {%k2}
15 // CHECK: encoding: [0x62,0xf2,0xfd,0x0a,0x54,0xcb]
16 vpopcntw %xmm3, %xmm1 {%k2}
17
18 // CHECK: vpopcntb (%rcx), %xmm1
19 // CHECK: encoding: [0x62,0xf2,0x7d,0x08,0x54,0x09]
20 vpopcntb (%rcx), %xmm1
21
22 // CHECK: vpopcntb -64(%rsp), %xmm1
23 // CHECK: encoding: [0x62,0xf2,0x7d,0x08,0x54,0x4c,0x24,0xfc]
24 vpopcntb -64(%rsp), %xmm1
25
26 // CHECK: vpopcntb 64(%rsp), %xmm1
27 // CHECK: encoding: [0x62,0xf2,0x7d,0x08,0x54,0x4c,0x24,0x04]
28 vpopcntb 64(%rsp), %xmm1
29
30 // CHECK: vpopcntb 268435456(%rcx,%r14,8), %xmm1
31 // CHECK: encoding: [0x62,0xb2,0x7d,0x08,0x54,0x8c,0xf1,0x00,0x00,0x00,0x10]
32 vpopcntb 268435456(%rcx,%r14,8), %xmm1
33
34 // CHECK: vpopcntb -536870912(%rcx,%r14,8), %xmm1
35 // CHECK: encoding: [0x62,0xb2,0x7d,0x08,0x54,0x8c,0xf1,0x00,0x00,0x00,0xe0]
36 vpopcntb -536870912(%rcx,%r14,8), %xmm1
37
38 // CHECK: vpopcntb -536870910(%rcx,%r14,8), %xmm1
39 // CHECK: encoding: [0x62,0xb2,0x7d,0x08,0x54,0x8c,0xf1,0x02,0x00,0x00,0xe0]
40 vpopcntb -536870910(%rcx,%r14,8), %xmm1
41
42 // CHECK: vpopcntw (%rcx), %xmm1
43 // CHECK: encoding: [0x62,0xf2,0xfd,0x08,0x54,0x09]
44 vpopcntw (%rcx), %xmm1
45
46 // CHECK: vpopcntw -64(%rsp), %xmm1
47 // CHECK: encoding: [0x62,0xf2,0xfd,0x08,0x54,0x4c,0x24,0xfc]
48 vpopcntw -64(%rsp), %xmm1
49
50 // CHECK: vpopcntw 64(%rsp), %xmm1
51 // CHECK: encoding: [0x62,0xf2,0xfd,0x08,0x54,0x4c,0x24,0x04]
52 vpopcntw 64(%rsp), %xmm1
53
54 // CHECK: vpopcntw 268435456(%rcx,%r14,8), %xmm1
55 // CHECK: encoding: [0x62,0xb2,0xfd,0x08,0x54,0x8c,0xf1,0x00,0x00,0x00,0x10]
56 vpopcntw 268435456(%rcx,%r14,8), %xmm1
57
58 // CHECK: vpopcntw -536870912(%rcx,%r14,8), %xmm1
59 // CHECK: encoding: [0x62,0xb2,0xfd,0x08,0x54,0x8c,0xf1,0x00,0x00,0x00,0xe0]
60 vpopcntw -536870912(%rcx,%r14,8), %xmm1
61
62 // CHECK: vpopcntw -536870910(%rcx,%r14,8), %xmm1
63 // CHECK: encoding: [0x62,0xb2,0xfd,0x08,0x54,0x8c,0xf1,0x02,0x00,0x00,0xe0]
64 vpopcntw -536870910(%rcx,%r14,8), %xmm1
65
66 // CHECK: vpopcntb (%rcx), %xmm21 {%k2}
67 // CHECK: encoding: [0x62,0xe2,0x7d,0x0a,0x54,0x29]
68 vpopcntb (%rcx), %xmm21 {%k2}
69
70 // CHECK: vpopcntb -64(%rsp), %xmm21 {%k2}
71 // CHECK: encoding: [0x62,0xe2,0x7d,0x0a,0x54,0x6c,0x24,0xfc]
72 vpopcntb -64(%rsp), %xmm21 {%k2}
73
74 // CHECK: vpopcntb 64(%rsp), %xmm21 {%k2}
75 // CHECK: encoding: [0x62,0xe2,0x7d,0x0a,0x54,0x6c,0x24,0x04]
76 vpopcntb 64(%rsp), %xmm21 {%k2}
77
78 // CHECK: vpopcntb 268435456(%rcx,%r14,8), %xmm21 {%k2}
79 // CHECK: encoding: [0x62,0xa2,0x7d,0x0a,0x54,0xac,0xf1,0x00,0x00,0x00,0x10]
80 vpopcntb 268435456(%rcx,%r14,8), %xmm21 {%k2}
81
82 // CHECK: vpopcntb -536870912(%rcx,%r14,8), %xmm21 {%k2}
83 // CHECK: encoding: [0x62,0xa2,0x7d,0x0a,0x54,0xac,0xf1,0x00,0x00,0x00,0xe0]
84 vpopcntb -536870912(%rcx,%r14,8), %xmm21 {%k2}
85
86 // CHECK: vpopcntb -536870910(%rcx,%r14,8), %xmm21 {%k2}
87 // CHECK: encoding: [0x62,0xa2,0x7d,0x0a,0x54,0xac,0xf1,0x02,0x00,0x00,0xe0]
88 vpopcntb -536870910(%rcx,%r14,8), %xmm21 {%k2}
89
90 // CHECK: vpopcntw (%rcx), %xmm21 {%k2}
91 // CHECK: encoding: [0x62,0xe2,0xfd,0x0a,0x54,0x29]
92 vpopcntw (%rcx), %xmm21 {%k2}
93
94 // CHECK: vpopcntw -64(%rsp), %xmm21 {%k2}
95 // CHECK: encoding: [0x62,0xe2,0xfd,0x0a,0x54,0x6c,0x24,0xfc]
96 vpopcntw -64(%rsp), %xmm21 {%k2}
97
98 // CHECK: vpopcntw 64(%rsp), %xmm21 {%k2}
99 // CHECK: encoding: [0x62,0xe2,0xfd,0x0a,0x54,0x6c,0x24,0x04]
100 vpopcntw 64(%rsp), %xmm21 {%k2}
101
102 // CHECK: vpopcntw 268435456(%rcx,%r14,8), %xmm21 {%k2}
103 // CHECK: encoding: [0x62,0xa2,0xfd,0x0a,0x54,0xac,0xf1,0x00,0x00,0x00,0x10]
104 vpopcntw 268435456(%rcx,%r14,8), %xmm21 {%k2}
105
106 // CHECK: vpopcntw -536870912(%rcx,%r14,8), %xmm21 {%k2}
107 // CHECK: encoding: [0x62,0xa2,0xfd,0x0a,0x54,0xac,0xf1,0x00,0x00,0x00,0xe0]
108 vpopcntw -536870912(%rcx,%r14,8), %xmm21 {%k2}
109
110 // CHECK: vpopcntw -536870910(%rcx,%r14,8), %xmm21 {%k2}
111 // CHECK: encoding: [0x62,0xa2,0xfd,0x0a,0x54,0xac,0xf1,0x02,0x00,0x00,0xe0]
112 vpopcntw -536870910(%rcx,%r14,8), %xmm21 {%k2}
113
114 // CHECK: vpopcntb %ymm23, %ymm21
115 // CHECK: encoding: [0x62,0xa2,0x7d,0x28,0x54,0xef]
116 vpopcntb %ymm23, %ymm21
117
118 // CHECK: vpopcntw %ymm23, %ymm21
119 // CHECK: encoding: [0x62,0xa2,0xfd,0x28,0x54,0xef]
120 vpopcntw %ymm23, %ymm21
121
122 // CHECK: vpopcntb %ymm3, %ymm1 {%k2}
123 // CHECK: encoding: [0x62,0xf2,0x7d,0x2a,0x54,0xcb]
124 vpopcntb %ymm3, %ymm1 {%k2}
125
126 // CHECK: vpopcntw %ymm3, %ymm1 {%k2}
127 // CHECK: encoding: [0x62,0xf2,0xfd,0x2a,0x54,0xcb]
128 vpopcntw %ymm3, %ymm1 {%k2}
129
130 // CHECK: vpopcntb (%rcx), %ymm1
131 // CHECK: encoding: [0x62,0xf2,0x7d,0x28,0x54,0x09]
132 vpopcntb (%rcx), %ymm1
133
134 // CHECK: vpopcntb -128(%rsp), %ymm1
135 // CHECK: encoding: [0x62,0xf2,0x7d,0x28,0x54,0x4c,0x24,0xfc]
136 vpopcntb -128(%rsp), %ymm1
137
138 // CHECK: vpopcntb 128(%rsp), %ymm1
139 // CHECK: encoding: [0x62,0xf2,0x7d,0x28,0x54,0x4c,0x24,0x04]
140 vpopcntb 128(%rsp), %ymm1
141
142 // CHECK: vpopcntb 268435456(%rcx,%r14,8), %ymm1
143 // CHECK: encoding: [0x62,0xb2,0x7d,0x28,0x54,0x8c,0xf1,0x00,0x00,0x00,0x10]
144 vpopcntb 268435456(%rcx,%r14,8), %ymm1
145
146 // CHECK: vpopcntb -536870912(%rcx,%r14,8), %ymm1
147 // CHECK: encoding: [0x62,0xb2,0x7d,0x28,0x54,0x8c,0xf1,0x00,0x00,0x00,0xe0]
148 vpopcntb -536870912(%rcx,%r14,8), %ymm1
149
150 // CHECK: vpopcntb -536870910(%rcx,%r14,8), %ymm1
151 // CHECK: encoding: [0x62,0xb2,0x7d,0x28,0x54,0x8c,0xf1,0x02,0x00,0x00,0xe0]
152 vpopcntb -536870910(%rcx,%r14,8), %ymm1
153
154 // CHECK: vpopcntw (%rcx), %ymm1
155 // CHECK: encoding: [0x62,0xf2,0xfd,0x28,0x54,0x09]
156 vpopcntw (%rcx), %ymm1
157
158 // CHECK: vpopcntw -128(%rsp), %ymm1
159 // CHECK: encoding: [0x62,0xf2,0xfd,0x28,0x54,0x4c,0x24,0xfc]
160 vpopcntw -128(%rsp), %ymm1
161
162 // CHECK: vpopcntw 128(%rsp), %ymm1
163 // CHECK: encoding: [0x62,0xf2,0xfd,0x28,0x54,0x4c,0x24,0x04]
164 vpopcntw 128(%rsp), %ymm1
165
166 // CHECK: vpopcntw 268435456(%rcx,%r14,8), %ymm1
167 // CHECK: encoding: [0x62,0xb2,0xfd,0x28,0x54,0x8c,0xf1,0x00,0x00,0x00,0x10]
168 vpopcntw 268435456(%rcx,%r14,8), %ymm1
169
170 // CHECK: vpopcntw -536870912(%rcx,%r14,8), %ymm1
171 // CHECK: encoding: [0x62,0xb2,0xfd,0x28,0x54,0x8c,0xf1,0x00,0x00,0x00,0xe0]
172 vpopcntw -536870912(%rcx,%r14,8), %ymm1
173
174 // CHECK: vpopcntw -536870910(%rcx,%r14,8), %ymm1
175 // CHECK: encoding: [0x62,0xb2,0xfd,0x28,0x54,0x8c,0xf1,0x02,0x00,0x00,0xe0]
176 vpopcntw -536870910(%rcx,%r14,8), %ymm1
177
178 // CHECK: vpopcntb (%rcx), %ymm21 {%k2}
179 // CHECK: encoding: [0x62,0xe2,0x7d,0x2a,0x54,0x29]
180 vpopcntb (%rcx), %ymm21 {%k2}
181
182 // CHECK: vpopcntb -128(%rsp), %ymm21 {%k2}
183 // CHECK: encoding: [0x62,0xe2,0x7d,0x2a,0x54,0x6c,0x24,0xfc]
184 vpopcntb -128(%rsp), %ymm21 {%k2}
185
186 // CHECK: vpopcntb 128(%rsp), %ymm21 {%k2}
187 // CHECK: encoding: [0x62,0xe2,0x7d,0x2a,0x54,0x6c,0x24,0x04]
188 vpopcntb 128(%rsp), %ymm21 {%k2}
189
190 // CHECK: vpopcntb 268435456(%rcx,%r14,8), %ymm21 {%k2}
191 // CHECK: encoding: [0x62,0xa2,0x7d,0x2a,0x54,0xac,0xf1,0x00,0x00,0x00,0x10]
192 vpopcntb 268435456(%rcx,%r14,8), %ymm21 {%k2}
193
194 // CHECK: vpopcntb -536870912(%rcx,%r14,8), %ymm21 {%k2}
195 // CHECK: encoding: [0x62,0xa2,0x7d,0x2a,0x54,0xac,0xf1,0x00,0x00,0x00,0xe0]
196 vpopcntb -536870912(%rcx,%r14,8), %ymm21 {%k2}
197
198 // CHECK: vpopcntb -536870910(%rcx,%r14,8), %ymm21 {%k2}
199 // CHECK: encoding: [0x62,0xa2,0x7d,0x2a,0x54,0xac,0xf1,0x02,0x00,0x00,0xe0]
200 vpopcntb -536870910(%rcx,%r14,8), %ymm21 {%k2}
201
202 // CHECK: vpopcntw (%rcx), %ymm21 {%k2}
203 // CHECK: encoding: [0x62,0xe2,0xfd,0x2a,0x54,0x29]
204 vpopcntw (%rcx), %ymm21 {%k2}
205
206 // CHECK: vpopcntw -128(%rsp), %ymm21 {%k2}
207 // CHECK: encoding: [0x62,0xe2,0xfd,0x2a,0x54,0x6c,0x24,0xfc]
208 vpopcntw -128(%rsp), %ymm21 {%k2}
209
210 // CHECK: vpopcntw 128(%rsp), %ymm21 {%k2}
211 // CHECK: encoding: [0x62,0xe2,0xfd,0x2a,0x54,0x6c,0x24,0x04]
212 vpopcntw 128(%rsp), %ymm21 {%k2}
213
214 // CHECK: vpopcntw 268435456(%rcx,%r14,8), %ymm21 {%k2}
215 // CHECK: encoding: [0x62,0xa2,0xfd,0x2a,0x54,0xac,0xf1,0x00,0x00,0x00,0x10]
216 vpopcntw 268435456(%rcx,%r14,8), %ymm21 {%k2}
217
218 // CHECK: vpopcntw -536870912(%rcx,%r14,8), %ymm21 {%k2}
219 // CHECK: encoding: [0x62,0xa2,0xfd,0x2a,0x54,0xac,0xf1,0x00,0x00,0x00,0xe0]
220 vpopcntw -536870912(%rcx,%r14,8), %ymm21 {%k2}
221
222 // CHECK: vpopcntw -536870910(%rcx,%r14,8), %ymm21 {%k2}
223 // CHECK: encoding: [0x62,0xa2,0xfd,0x2a,0x54,0xac,0xf1,0x02,0x00,0x00,0xe0]
224 vpopcntw -536870910(%rcx,%r14,8), %ymm21 {%k2}
225