diff --git a/llvm/lib/Target/X86/X86InstrSSE.td b/llvm/lib/Target/X86/X86InstrSSE.td index d87891d6a735..5e96eecf8a4e 100644 --- a/llvm/lib/Target/X86/X86InstrSSE.td +++ b/llvm/lib/Target/X86/X86InstrSSE.td @@ -8037,51 +8037,26 @@ defm VPSRAVD : avx2_var_shift<0x46, "vpsravd", sra, v4i32, v8i32>; //===----------------------------------------------------------------------===// // VGATHER - GATHER Operations multiclass avx2_gather opc, string OpcodeStr, - RegisterClass RC256, X86MemOperand memop256, - Intrinsic IntGather128, Intrinsic IntGather256> { + RegisterClass RC256, X86MemOperand memop256> { def rm : AVX28I, VEX_4VOp3; def Yrm : AVX28I, VEX_4VOp3, VEX_L; } let Constraints = "$src1 = $dst" in { - defm VGATHERDPD : avx2_gather<0x92, "vgatherdpd", - VR256, v128mem, - int_x86_avx2_gather_d_pd, - int_x86_avx2_gather_d_pd_256>, VEX_W; - defm VGATHERQPD : avx2_gather<0x93, "vgatherqpd", - VR256, v256mem, - int_x86_avx2_gather_q_pd, - int_x86_avx2_gather_q_pd_256>, VEX_W; - defm VGATHERDPS : avx2_gather<0x92, "vgatherdps", - VR256, v256mem, - int_x86_avx2_gather_d_ps, - int_x86_avx2_gather_d_ps_256>; - defm VGATHERQPS : avx2_gather<0x93, "vgatherqps", - VR128, v256mem, - int_x86_avx2_gather_q_ps, - int_x86_avx2_gather_q_ps_256>; - defm VPGATHERDQ : avx2_gather<0x90, "vpgatherdq", - VR256, v128mem, - int_x86_avx2_gather_d_q, - int_x86_avx2_gather_d_q_256>, VEX_W; - defm VPGATHERQQ : avx2_gather<0x91, "vpgatherqq", - VR256, v256mem, - int_x86_avx2_gather_q_q, - int_x86_avx2_gather_q_q_256>, VEX_W; - defm VPGATHERDD : avx2_gather<0x90, "vpgatherdd", - VR256, v256mem, - int_x86_avx2_gather_d_d, - int_x86_avx2_gather_d_d_256>; - defm VPGATHERQD : avx2_gather<0x91, "vpgatherqd", - VR128, v256mem, - int_x86_avx2_gather_q_d, - int_x86_avx2_gather_q_d_256>; + defm VGATHERDPD : avx2_gather<0x92, "vgatherdpd", VR256, v128mem>, VEX_W; + defm VGATHERQPD : avx2_gather<0x93, "vgatherqpd", VR256, v256mem>, VEX_W; + defm VGATHERDPS : avx2_gather<0x92, "vgatherdps", VR256, v256mem>; + defm VGATHERQPS : avx2_gather<0x93, "vgatherqps", VR128, v256mem>; + defm VPGATHERDQ : avx2_gather<0x90, "vpgatherdq", VR256, v128mem>, VEX_W; + defm VPGATHERQQ : avx2_gather<0x91, "vpgatherqq", VR256, v256mem>, VEX_W; + defm VPGATHERDD : avx2_gather<0x90, "vpgatherdd", VR256, v256mem>; + defm VPGATHERQD : avx2_gather<0x91, "vpgatherqd", VR128, v256mem>; } diff --git a/llvm/test/MC/Disassembler/X86/simple-tests.txt b/llvm/test/MC/Disassembler/X86/simple-tests.txt index 712c95aa72a5..15e046feaf27 100644 --- a/llvm/test/MC/Disassembler/X86/simple-tests.txt +++ b/llvm/test/MC/Disassembler/X86/simple-tests.txt @@ -726,28 +726,28 @@ 0xc4 0xe3 0xe1 0x48 0x40 0x04 0x21 # CHECK: vgatherdpd %xmm0, (%rdi,%xmm1,2), %xmm2 -0xc4 0xe2 0xe9 0x92 0x04 0x4f +0xc4 0xe2 0xf9 0x92 0x14 0x4f # CHECK: vgatherdpd %ymm0, (%rdi,%xmm1,2), %ymm2 -0xc4 0xe2 0xed 0x92 0x04 0x4f +0xc4 0xe2 0xfd 0x92 0x14 0x4f # CHECK: vgatherqps %xmm8, (%r15,%xmm9,2), %xmm10 -0xc4 0x02 0x29 0x93 0x04 0x4f +0xc4 0x02 0x39 0x93 0x14 0x4f # CHECK: vgatherqps %xmm8, (%r15,%ymm9,2), %xmm10 -0xc4 0x02 0x2d 0x93 0x04 0x4f +0xc4 0x02 0x3d 0x93 0x14 0x4f # CHECK: vpgatherdq %xmm0, (%rdi,%xmm1,2), %xmm2 -0xc4 0xe2 0xe9 0x90 0x04 0x4f +0xc4 0xe2 0xf9 0x90 0x14 0x4f # CHECK: vpgatherdq %ymm0, (%rdi,%xmm1,2), %ymm2 -0xc4 0xe2 0xed 0x90 0x04 0x4f +0xc4 0xe2 0xfd 0x90 0x14 0x4f # CHECK: vpgatherqd %xmm8, (%r15,%xmm9,2), %xmm10 -0xc4 0x02 0x29 0x91 0x04 0x4f +0xc4 0x02 0x39 0x91 0x14 0x4f # CHECK: vpgatherqd %xmm8, (%r15,%ymm9,2), %xmm10 -0xc4 0x02 0x2d 0x91 0x04 0x4f +0xc4 0x02 0x3d 0x91 0x14 0x4f # rdar://8812056 lldb doesn't print the x86 lock prefix when disassembling # CHECK: lock diff --git a/llvm/test/MC/X86/x86_64-avx-encoding.s b/llvm/test/MC/X86/x86_64-avx-encoding.s index b9943bafe775..9333246d8c02 100644 --- a/llvm/test/MC/X86/x86_64-avx-encoding.s +++ b/llvm/test/MC/X86/x86_64-avx-encoding.s @@ -4123,33 +4123,33 @@ _foo2: vblendvps %ymm1, _foo2(%rip), %ymm0, %ymm0 // CHECK: vgatherdpd %xmm0, (%rdi,%xmm1,2), %xmm2 -// CHECK: encoding: [0xc4,0xe2,0xe9,0x92,0x04,0x4f] +// CHECK: encoding: [0xc4,0xe2,0xf9,0x92,0x14,0x4f] vgatherdpd %xmm0, (%rdi,%xmm1,2), %xmm2 // CHECK: vgatherdpd %ymm0, (%rdi,%xmm1,2), %ymm2 -// CHECK: encoding: [0xc4,0xe2,0xed,0x92,0x04,0x4f] +// CHECK: encoding: [0xc4,0xe2,0xfd,0x92,0x14,0x4f] vgatherdpd %ymm0, (%rdi,%xmm1,2), %ymm2 // CHECK: vgatherqps %xmm8, (%r15,%xmm9,2), %xmm10 -// CHECK: encoding: [0xc4,0x02,0x29,0x93,0x04,0x4f] +// CHECK: encoding: [0xc4,0x02,0x39,0x93,0x14,0x4f] vgatherqps %xmm8, (%r15,%xmm9,2), %xmm10 // CHECK: vgatherqps %xmm8, (%r15,%ymm9,2), %xmm10 -// CHECK: encoding: [0xc4,0x02,0x2d,0x93,0x04,0x4f] +// CHECK: encoding: [0xc4,0x02,0x3d,0x93,0x14,0x4f] vgatherqps %xmm8, (%r15,%ymm9,2), %xmm10 // CHECK: vpgatherdq %xmm0, (%rdi,%xmm1,2), %xmm2 -// CHECK: encoding: [0xc4,0xe2,0xe9,0x90,0x04,0x4f] +// CHECK: encoding: [0xc4,0xe2,0xf9,0x90,0x14,0x4f] vpgatherdq %xmm0, (%rdi,%xmm1,2), %xmm2 // CHECK: vpgatherdq %ymm0, (%rdi,%xmm1,2), %ymm2 -// CHECK: encoding: [0xc4,0xe2,0xed,0x90,0x04,0x4f] +// CHECK: encoding: [0xc4,0xe2,0xfd,0x90,0x14,0x4f] vpgatherdq %ymm0, (%rdi,%xmm1,2), %ymm2 // CHECK: vpgatherqd %xmm8, (%r15,%xmm9,2), %xmm10 -// CHECK: encoding: [0xc4,0x02,0x29,0x91,0x04,0x4f] +// CHECK: encoding: [0xc4,0x02,0x39,0x91,0x14,0x4f] vpgatherqd %xmm8, (%r15,%xmm9,2), %xmm10 // CHECK: vpgatherqd %xmm8, (%r15,%ymm9,2), %xmm10 -// CHECK: encoding: [0xc4,0x02,0x2d,0x91,0x04,0x4f] +// CHECK: encoding: [0xc4,0x02,0x3d,0x91,0x14,0x4f] vpgatherqd %xmm8, (%r15,%ymm9,2), %xmm10