1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373
|
# RUN: llvm-mc --disassemble %s -triple=x86_64-apple-darwin9 -mcpu=knl | FileCheck %s
# RUN: llvm-mc --disassemble %s -triple=x86_64-apple-darwin9 -mcpu=skx | FileCheck --check-prefix=CHECK-SKX %s
# RUN: llvm-mc --disassemble %s -triple=x86_64-apple-darwin9 -mattr=+avx512vpopcntdq | FileCheck %s --check-prefix=AVX512VPOPCNTDQ
# CHECK: vpbroadcastd %xmm18, %zmm28 {%k7} {z}
0x62 0x22 0x7d 0xcf 0x58 0xe2
# CHECK: vbroadcastss (%rsp), %zmm28
0x62 0x62 0x7d 0x48 0x18 0x24 0x24
# CHECK: vblendmpd (%rsi), %zmm2, %zmm8 {%k7}
0x62 0x72 0xed 0x4f 0x65 0x06
# CHECK: vpermpd (%rsi,%r10,4), %zmm2, %zmm8
0x62 0x32 0xed 0x48 0x16 0x04 0x96
# CHECK: vpbroadcastmw2d %k2, %zmm8
0x62 0x72 0x7e 0x48 0x3a 0xc2
# CHECK-SKX: vpbroadcastmw2d %k2, %xmm8
0x62 0x72 0x7e 0x08 0x3a 0xc2
# CHECK-SKX: vpbroadcastmw2d %k2, %ymm8
0x62 0x72 0x7e 0x28 0x3a 0xc2
# CHECK: vpbroadcastq (%r9,%rax), %zmm28
0x62 0x42 0xfd 0x48 0x59 0x24 0x01
# CHECK: vbroadcastss %xmm0, %zmm1
0x62 0xf2 0x7d 0x48 0x18 0xc8
# CHECK: vextracti32x4 $4, %zmm0, (%r10)
0x62 0xd3 0x7d 0x48 0x39 0x02 0x04
# CHECK: vextracti32x4 $4, %zmm0, %xmm1
0x62 0xf3 0x7d 0x48 0x39 0xc1 0x04
# CHECK: vinserti32x4 $1, %xmm21, %zmm5, %zmm17
0x62 0xa3 0x55 0x48 0x38 0xcd 0x01
# CHECK: vmovaps %zmm21, %zmm5 {%k3}
0x62 0xb1 0x7c 0x4b 0x28 0xed
# CHECK: vgatherdps (%rsi,%zmm0,4), %zmm1 {%k2}
0x62 0xf2 0x7d 0x4a 0x92 0x0c 0x86
# CHECK: vgatherdpd (%rsi,%ymm0,4), %zmm1 {%k2}
0x62 0xf2 0xfd 0x4a 0x92 0x0c 0x86
# CHECK: vgatherqps (%r13,%zmm4), %ymm5 {%k2}
0x62 0xd2 0x7d 0x4a 0x93 0x6c 0x25 0x00
# CHECK: vpslld $16, %zmm21, %zmm22
0x62 0xb1 0x4d 0x40 0x72 0xf5 0x10
# CHECK: vpord %zmm22, %zmm21, %zmm23
0x62 0xa1 0x55 0x40 0xeb 0xfe
#####################################################
# MASK INSTRUCTIONS #
#####################################################
# CHECK: kshiftlw $3, %k1, %k2
0xc4 0xe3 0xf9 0x32 0xd1 0x03
# CHECK: kmovw (%rdi), %k1
0xc5 0xf8 0x90 0x0f
# CHECK: kmovw %k1, %eax
0xc5 0xf8 0x93 0xc1
# CHECK: kandw %k1, %k2, %k3
0xc5 0xec 0x41 0xd9
# CHECK: kmovw %k5, %k1
0xc5 0xf8 0x90 0xcd
#####################################################
# COMPRESSED DISPLACEMENT #
#####################################################
# TupleType = FVM
# CHECK: vmovdqu32 %zmm0, -448(%rcx)
0x62 0xf1 0x7e 0x48 0x7f 0x41 0xf9
# TupleType = T1S, 64-bit eltsize
# CHECK: vaddsd 256(%rdx), %xmm0, %xmm16
0x62 0xe1 0xff 0x08 0x58 0x42 0x20
# TupleType = T1S, 32-bit eltsize
# CHECK: vaddss 256(%rdx), %xmm0, %xmm16
0x62 0xe1 0x7e 0x08 0x58 0x42 0x40
# TupleType = FV
# CHECK: vaddpd 256(%rdx), %zmm0, %zmm16
0x62 0xe1 0xfd 0x48 0x58 0x42 0x04
# TupleType = FV, broadcast, 64-bit eltsize
# CHECK: vaddpd 256(%rdx){1to8}, %zmm0, %zmm16
0x62 0xe1 0xfd 0x58 0x58 0x42 0x20
# TupleType = FV, broadcast, 32-bit eltsize
# CHECK: vaddps 256(%rdx){1to16}, %zmm0, %zmm16
0x62 0xe1 0x7c 0x58 0x58 0x42 0x40
# TupleType = T4
# CHECK: vbroadcasti32x4 256(%rdx), %zmm16
0x62 0xe2 0x7d 0x48 0x5a 0x42 0x10
# Cases where we can't use cdisp8
# CHECK: vaddss 255(%rdx), %xmm0, %xmm16
0x62 0xe1 0x7e 0x08 0x58 0x82 0xff 0x00 0x00 0x00
# CHECK: vaddss 1024(%rdx), %xmm0, %xmm16
0x62 0xe1 0x7e 0x08 0x58 0x82 0x00 0x04 0x00 0x00
# CHECK: vpcmpeqd %zmm10, %zmm25, %k5
0x62 0xd3 0x35 0x40 0x1f 0xea 0x0
# CHECK: vpcmpltd %zmm10, %zmm25, %k5
0x62 0xd3 0x35 0x40 0x1f 0xea 0x1
# CHECK: vpcmpled %zmm10, %zmm25, %k5
0x62 0xd3 0x35 0x40 0x1f 0xea 0x2
# CHECK: vpcmpd $3, %zmm10, %zmm25, %k5
0x62 0xd3 0x35 0x40 0x1f 0xea 0x3
# CHECK: vpcmpneqd %zmm10, %zmm25, %k5
0x62 0xd3 0x35 0x40 0x1f 0xea 0x4
# CHECK: vpcmpnltd %zmm10, %zmm25, %k5
0x62 0xd3 0x35 0x40 0x1f 0xea 0x5
# CHECK: vpcmpnled %zmm10, %zmm25, %k5
0x62 0xd3 0x35 0x40 0x1f 0xea 0x6
# CHECK: vpcmpd $7, %zmm10, %zmm25, %k5
0x62 0xd3 0x35 0x40 0x1f 0xea 0x7
# CHECK: vpcmpd $8, %zmm10, %zmm25, %k5
0x62 0xd3 0x35 0x40 0x1f 0xea 0x8
# CHECK: vcmppd $127, {sae}, %zmm27, %zmm11, %k4
0x62 0x91 0xa5 0x58 0xc2 0xe3 0x7f
# CHECK: vcmpsd $204, (%rax), %xmm4, %k5
0x62 0xf1 0xdf 0x8 0xc2 0x28 0xcc
# CHECK: vcmpss $204, (%rax), %xmm4, %k5
0x62 0xf1 0x5e 0x08 0xc2 0x28 0xcc
# CHECK: vcmpsd $204, %xmm3, %xmm4, %k5
0x62 0xf1 0xdf 0x08 0xc2 0xeb 0xcc
# CHECK: vcmpss $204, %xmm3, %xmm4, %k5
0x62 0xf1 0x5e 0x08 0xc2 0xeb 0xcc
# CHECK: vcmpsd $204, {sae}, %xmm3, %xmm4, %k5
0x62 0xf1 0xdf 0x18 0xc2 0xeb 0xcc
# CHECK: vcmpss $204, {sae}, %xmm3, %xmm4, %k5
0x62 0xf1 0x5e 0x18 0xc2 0xeb 0xcc
# CHECK: vcmppd $127, %ymm27, %ymm11, %k4
0x62 0x91 0xa5 0x28 0xc2 0xe3 0x7f
# CHECK: vcmpps $127, %ymm27, %ymm11, %k4
0x62 0x91 0x24 0x28 0xc2 0xe3 0x7f
# CHECK: vcmppd $127, %xmm27, %xmm11, %k4
0x62 0x91 0xa5 0x08 0xc2 0xe3 0x7f
# CHECK: vcmpps $127, %xmm27, %xmm11, %k4
0x62 0x91 0x24 0x08 0xc2 0xe3 0x7f
# CHECK: vpgatherdd 256(%r9,%xmm31), %xmm17 {%k1}
0x62 0x82 0x7d 0x01 0x90 0x4c 0x39 0x40
# CHECK: vpgatherdd 256(%r9,%ymm31), %ymm19 {%k1}
0x62 0x82 0x7d 0x21 0x90 0x5c 0x39 0x40
# CHECK: vpgatherdq 256(%r9,%xmm31), %xmm17 {%k1}
0x62 0x82 0xfd 0x01 0x90 0x4c 0x39 0x20
# CHECK: vpgatherdq 256(%r9,%xmm31), %ymm26 {%k1}
0x62 0x02 0xfd 0x21 0x90 0x54 0x39 0x20
# CHECK: vpgatherqd 256(%r9,%xmm31), %xmm21 {%k1}
0x62 0x82 0x7d 0x01 0x91 0x6c 0x39 0x40
# CHECK: vpgatherqd 256(%r9,%ymm31), %xmm25 {%k1}
0x62 0x02 0x7d 0x21 0x91 0x4c 0x39 0x40
# CHECK: vpgatherqq 256(%r9,%xmm31), %xmm18 {%k1}
0x62 0x82 0xfd 0x01 0x91 0x54 0x39 0x20
# CHECK: vpgatherqq 256(%r9,%ymm31), %ymm19 {%k1}
0x62 0x82 0xfd 0x21 0x91 0x5c 0x39 0x20
# CHECK: vgatherdpd 256(%r9,%xmm31), %xmm17 {%k1}
0x62 0x82 0xfd 0x01 0x92 0x4c 0x39 0x20
# CHECK: vgatherdpd 256(%r9,%xmm31), %ymm23 {%k1}
0x62 0x82 0xfd 0x21 0x92 0x7c 0x39 0x20
# CHECK: vgatherdps 256(%r9,%xmm31), %xmm18 {%k1}
0x62 0x82 0x7d 0x01 0x92 0x54 0x39 0x40
# CHECK: vgatherdps 256(%r9,%ymm31), %ymm27 {%k1}
0x62 0x02 0x7d 0x21 0x92 0x5c 0x39 0x40
# CHECK: vgatherqpd 256(%r9,%xmm31), %xmm17 {%k1}
0x62 0x82 0xfd 0x01 0x93 0x4c 0x39 0x20
# CHECK: vgatherqpd 256(%r9,%ymm31), %ymm29 {%k1}
0x62 0x02 0xfd 0x21 0x93 0x6c 0x39 0x20
# CHECK: vgatherqps 256(%r9,%xmm31), %xmm21 {%k1}
0x62 0x82 0x7d 0x01 0x93 0x6c 0x39 0x40
# CHECK: vgatherqps 256(%r9,%ymm31), %xmm19 {%k1}
0x62 0x82 0x7d 0x21 0x93 0x5c 0x39 0x40
# CHECK: vpscatterdd %xmm20, 256(%r9,%xmm31) {%k1}
0x62 0x82 0x7d 0x01 0xa0 0x64 0x39 0x40
# CHECK: vpscatterdd %ymm28, 256(%r9,%ymm31) {%k1}
0x62 0x02 0x7d 0x21 0xa0 0x64 0x39 0x40
# CHECK: vpscatterdq %xmm21, 256(%r9,%xmm31) {%k1}
0x62 0x82 0xfd 0x01 0xa0 0x6c 0x39 0x20
# CHECK: vpscatterdq %ymm28, 256(%r9,%xmm31) {%k1}
0x62 0x02 0xfd 0x21 0xa0 0x64 0x39 0x20
# CHECK: vpscatterqd %xmm22, 256(%r9,%xmm31) {%k1}
0x62 0x82 0x7d 0x01 0xa1 0x74 0x39 0x40
# CHECK: vpscatterqd %xmm24, 256(%r9,%ymm31) {%k1}
0x62 0x02 0x7d 0x21 0xa1 0x44 0x39 0x40
# CHECK: vpscatterqq %xmm28, 256(%r9,%xmm31) {%k1}
0x62 0x02 0xfd 0x01 0xa1 0x64 0x39 0x20
# CHECK: vpscatterqq %ymm19, 256(%r9,%ymm31) {%k1}
0x62 0x82 0xfd 0x21 0xa1 0x5c 0x39 0x20
# CHECK: vscatterdps %xmm20, 256(%r9,%xmm31) {%k1}
0x62 0x82 0x7d 0x01 0xa2 0x64 0x39 0x40
# CHECK: vscatterdps %ymm28, 256(%r9,%ymm31) {%k1}
0x62 0x02 0x7d 0x21 0xa2 0x64 0x39 0x40
# CHECK: vscatterdpd %xmm21, 256(%r9,%xmm31) {%k1}
0x62 0x82 0xfd 0x01 0xa2 0x6c 0x39 0x20
# CHECK: vscatterdpd %ymm28, 256(%r9,%xmm31) {%k1}
0x62 0x02 0xfd 0x21 0xa2 0x64 0x39 0x20
# CHECK: vscatterqps %xmm22, 256(%r9,%xmm31) {%k1}
0x62 0x82 0x7d 0x01 0xa3 0x74 0x39 0x40
# CHECK: vscatterqps %xmm24, 256(%r9,%ymm31) {%k1}
0x62 0x02 0x7d 0x21 0xa3 0x44 0x39 0x40
# CHECK: vscatterqpd %xmm28, 256(%r9,%xmm31) {%k1}
0x62 0x02 0xfd 0x01 0xa3 0x64 0x39 0x20
# CHECK: vscatterqpd %ymm19, 256(%r9,%ymm31) {%k1}
0x62 0x82 0xfd 0x21 0xa3 0x5c 0x39 0x20
#####################################################
# POPULATION COUNT #
#####################################################
# AVX512VPOPCNTDQ: vpopcntd %zmm21, %zmm26 {%k4}
0x62 0x22 0x7d 0x4c 0x55 0xd5
# AVX512VPOPCNTDQ: vpopcntd %zmm21, %zmm26 {%k4} {z}
0x62 0x22 0x7d 0xcc 0x55 0xd5
# AVX512VPOPCNTDQ: vpopcntd (%rcx), %zmm26
0x62 0x62 0x7d 0x48 0x55 0x11
# AVX512VPOPCNTDQ: vpopcntq %zmm21, %zmm17 {%k6}
0x62 0xa2 0xfd 0x4e 0x55 0xcd
# AVX512VPOPCNTDQ: vpopcntq %zmm21, %zmm17 {%k6} {z}
0x62 0xa2 0xfd 0xce 0x55 0xcd
# AVX512VPOPCNTDQ: vpopcntq (%rcx), %zmm17
0x62 0xe2 0xfd 0x48 0x55 0x09
#####################################################
# SAE ATTRIBUTE #
#####################################################
# CHECK: vcomisd {sae}, %xmm2, %xmm1
0x62 0xf1 0xfd 0x18 0x2f 0xca
# Same as above but ignore EVEX L'L bits.
# CHECK: vcomisd {sae}, %xmm2, %xmm1
0x62 0xf1 0xfd 0x78 0x2f 0xca
# CHECK: vminpd {sae}, %zmm2, %zmm17, %zmm19
0x62 0xe1 0xf5 0x10 0x5d 0xda
# Ignore EVEX L'L bits.
# CHECK: vminpd {sae}, %zmm2, %zmm17, %zmm19
0x62 0xe1 0xf5 0x30 0x5d 0xda
# Ignore EVEX L'L bits.
# CHECK: vminpd {sae}, %zmm2, %zmm17, %zmm19
0x62 0xe1 0xf5 0x50 0x5d 0xda
# Ignore EVEX L'L bits.
# CHECK: vminpd {sae}, %zmm2, %zmm17, %zmm19
0x62 0xe1 0xf5 0x70 0x5d 0xda
# CHECK: vcmppd $127, {sae}, %zmm27, %zmm11, %k4
0x62 0x91 0xa5 0x18 0xc2 0xe3 0x7f
# CHECK: vrsqrt28pd {sae}, %zmm2, %zmm17
0x62 0xe2 0xfd 0x18 0xcc 0xca
#####################################################
# ROUNDING CONTROL #
#####################################################
# Verify all rounding modes work.
# CHECK: vaddps {rn-sae}, %zmm2, %zmm17, %zmm19
0x62 0xe1 0x74 0x10 0x58 0xda
# CHECK: vaddps {rd-sae}, %zmm2, %zmm17, %zmm19
0x62 0xe1 0x74 0x30 0x58 0xda
# CHECK: vaddps {ru-sae}, %zmm2, %zmm17, %zmm19
0x62 0xe1 0x74 0x50 0x58 0xda
# CHECK: vaddps {rz-sae}, %zmm2, %zmm17, %zmm19
0x62 0xe1 0x74 0x70 0x58 0xda
# CHECK: vmulss {rn-sae}, %xmm2, %xmm17, %xmm19
0x62 0xe1 0x76 0x10 0x59 0xda
# CHECK: vmulss {rd-sae}, %xmm2, %xmm17, %xmm19
0x62 0xe1 0x76 0x30 0x59 0xda
# CHECK: vmulss {ru-sae}, %xmm2, %xmm17, %xmm19
0x62 0xe1 0x76 0x50 0x59 0xda
# CHECK: vmulss {rz-sae}, %xmm2, %xmm17, %xmm19
0x62 0xe1 0x76 0x70 0x59 0xda
# CHECK: vscalefpd {rn-sae}, %zmm2, %zmm17, %zmm19
0x62 0xe2 0xf5 0x10 0x2c 0xda
# CHECK: vscalefpd {rd-sae}, %zmm2, %zmm17, %zmm19
0x62 0xe2 0xf5 0x30 0x2c 0xda
# CHECK: vscalefpd {ru-sae}, %zmm2, %zmm17, %zmm19
0x62 0xe2 0xf5 0x50 0x2c 0xda
# CHECK: vscalefpd {rz-sae}, %zmm2, %zmm17, %zmm19
0x62 0xe2 0xf5 0x70 0x2c 0xda
# CHECK: vcvtqq2ps {rd-sae}, %zmm2, %ymm17
0x62 0xe1 0xfc 0x38 0x5b 0xca
# CHECK: vsqrtpd {rd-sae}, %zmm2, %zmm17
0x62 0xe1 0xfd 0x38 0x51 0xca
|