Index: llvm/trunk/lib/Target/AMDGPU/BUFInstructions.td =================================================================== --- llvm/trunk/lib/Target/AMDGPU/BUFInstructions.td +++ llvm/trunk/lib/Target/AMDGPU/BUFInstructions.td @@ -550,6 +550,9 @@ defm BUFFER_LOAD_DWORDX2 : MUBUF_Pseudo_Loads < "buffer_load_dwordx2", VReg_64, v2i32, mubuf_load >; +defm BUFFER_LOAD_DWORDX3 : MUBUF_Pseudo_Loads < + "buffer_load_dwordx3", VReg_96, untyped, mubuf_load +>; defm BUFFER_LOAD_DWORDX4 : MUBUF_Pseudo_Loads < "buffer_load_dwordx4", VReg_128, v4i32, mubuf_load >; @@ -565,6 +568,9 @@ defm BUFFER_STORE_DWORDX2 : MUBUF_Pseudo_Stores < "buffer_store_dwordx2", VReg_64, v2i32, global_store >; +defm BUFFER_STORE_DWORDX3 : MUBUF_Pseudo_Stores < + "buffer_store_dwordx3", VReg_96, untyped, global_store +>; defm BUFFER_STORE_DWORDX4 : MUBUF_Pseudo_Stores < "buffer_store_dwordx4", VReg_128, v4i32, global_store >; @@ -1118,11 +1124,13 @@ defm BUFFER_LOAD_DWORD : MUBUF_Real_AllAddr_si <0x0c>; defm BUFFER_LOAD_DWORDX2 : MUBUF_Real_AllAddr_si <0x0d>; defm BUFFER_LOAD_DWORDX4 : MUBUF_Real_AllAddr_si <0x0e>; +defm BUFFER_LOAD_DWORDX3 : MUBUF_Real_AllAddr_si <0x0f>; defm BUFFER_STORE_BYTE : MUBUF_Real_AllAddr_si <0x18>; defm BUFFER_STORE_SHORT : MUBUF_Real_AllAddr_si <0x1a>; defm BUFFER_STORE_DWORD : MUBUF_Real_AllAddr_si <0x1c>; defm BUFFER_STORE_DWORDX2 : MUBUF_Real_AllAddr_si <0x1d>; defm BUFFER_STORE_DWORDX4 : MUBUF_Real_AllAddr_si <0x1e>; +defm BUFFER_STORE_DWORDX3 : MUBUF_Real_AllAddr_si <0x1f>; defm BUFFER_ATOMIC_SWAP : MUBUF_Real_Atomic_si <0x30>; defm BUFFER_ATOMIC_CMPSWAP : MUBUF_Real_Atomic_si <0x31>; @@ -1249,11 +1257,13 @@ defm BUFFER_LOAD_SSHORT : MUBUF_Real_AllAddr_vi <0x13>; defm BUFFER_LOAD_DWORD : MUBUF_Real_AllAddr_vi <0x14>; defm BUFFER_LOAD_DWORDX2 : MUBUF_Real_AllAddr_vi <0x15>; +defm BUFFER_LOAD_DWORDX3 : MUBUF_Real_AllAddr_vi <0x16>; defm BUFFER_LOAD_DWORDX4 : MUBUF_Real_AllAddr_vi <0x17>; defm BUFFER_STORE_BYTE : MUBUF_Real_AllAddr_vi <0x18>; defm BUFFER_STORE_SHORT : MUBUF_Real_AllAddr_vi <0x1a>; defm BUFFER_STORE_DWORD : MUBUF_Real_AllAddr_vi <0x1c>; defm BUFFER_STORE_DWORDX2 : MUBUF_Real_AllAddr_vi <0x1d>; +defm BUFFER_STORE_DWORDX3 : MUBUF_Real_AllAddr_vi <0x1e>; defm BUFFER_STORE_DWORDX4 : MUBUF_Real_AllAddr_vi <0x1f>; defm BUFFER_ATOMIC_SWAP : MUBUF_Real_Atomic_vi <0x40>; Index: llvm/trunk/test/MC/AMDGPU/mubuf.s =================================================================== --- llvm/trunk/test/MC/AMDGPU/mubuf.s +++ llvm/trunk/test/MC/AMDGPU/mubuf.s @@ -446,6 +446,10 @@ // SICI: buffer_load_dwordx2 v[1:2], off, s[4:7], s1 ; encoding: [0x00,0x00,0x34,0xe0,0x00,0x01,0x01,0x01] // VI: buffer_load_dwordx2 v[1:2], off, s[4:7], s1 ; encoding: [0x00,0x00,0x54,0xe0,0x00,0x01,0x01,0x01] +buffer_load_dwordx3 v[0:2], off, s[4:7], s0 offset:4095 +// SICI: buffer_load_dwordx3 v[0:2], off, s[4:7], s0 offset:4095 ; encoding: [0xff,0x0f,0x3c,0xe0,0x00,0x00,0x01,0x00] +// VI: buffer_load_dwordx3 v[0:2], off, s[4:7], s0 offset:4095 ; encoding: [0xff,0x0f,0x58,0xe0,0x00,0x00,0x01,0x00] + buffer_load_dwordx4 v[1:4], off, s[4:7], s1 // SICI: buffer_load_dwordx4 v[1:4], off, s[4:7], s1 ; encoding: [0x00,0x00,0x38,0xe0,0x00,0x01,0x01,0x01] // VI: buffer_load_dwordx4 v[1:4], off, s[4:7], s1 ; encoding: [0x00,0x00,0x5c,0xe0,0x00,0x01,0x01,0x01] @@ -474,6 +478,10 @@ // SICI: buffer_store_dwordx2 v[1:2], off, s[4:7], s1 ; encoding: [0x00,0x00,0x74,0xe0,0x00,0x01,0x01,0x01] // VI: buffer_store_dwordx2 v[1:2], off, s[4:7], s1 ; encoding: [0x00,0x00,0x74,0xe0,0x00,0x01,0x01,0x01] +buffer_store_dwordx3 v[0:2], off, s[4:7], s0 offset:4095 +// SICI: buffer_store_dwordx3 v[0:2], off, s[4:7], s0 offset:4095 ; encoding: [0xff,0x0f,0x7c,0xe0,0x00,0x00,0x01,0x00] +// VI: buffer_store_dwordx3 v[0:2], off, s[4:7], s0 offset:4095 ; encoding: [0xff,0x0f,0x78,0xe0,0x00,0x00,0x01,0x00] + buffer_store_dwordx4 v[1:4], off, s[4:7], s1 // SICI: buffer_store_dwordx4 v[1:4], off, s[4:7], s1 ; encoding: [0x00,0x00,0x78,0xe0,0x00,0x01,0x01,0x01] // VI: buffer_store_dwordx4 v[1:4], off, s[4:7], s1 ; encoding: [0x00,0x00,0x7c,0xe0,0x00,0x01,0x01,0x01] Index: llvm/trunk/test/MC/Disassembler/AMDGPU/mubuf_vi.txt =================================================================== --- llvm/trunk/test/MC/Disassembler/AMDGPU/mubuf_vi.txt +++ llvm/trunk/test/MC/Disassembler/AMDGPU/mubuf_vi.txt @@ -210,6 +210,9 @@ # VI: buffer_load_dwordx2 v[1:2], off, s[4:7], s1 ; encoding: [0x00,0x00,0x54,0xe0,0x00,0x01,0x01,0x01] 0x00 0x00 0x54 0xe0 0x00 0x01 0x01 0x01 +# VI: buffer_load_dwordx3 v[0:2], off, s[4:7], s0 offset:4095 ; encoding: [0xff,0x0f,0x58,0xe0,0x00,0x00,0x01,0x00] +0xff,0x0f,0x58,0xe0,0x00,0x00,0x01,0x00 + # VI: buffer_load_dwordx4 v[1:4], off, s[4:7], s1 ; encoding: [0x00,0x00,0x5c,0xe0,0x00,0x01,0x01,0x01] 0x00 0x00 0x5c 0xe0 0x00 0x01 0x01 0x01 @@ -225,6 +228,9 @@ # VI: buffer_store_dwordx2 v[1:2], off, s[4:7], s1 ; encoding: [0x00,0x00,0x74,0xe0,0x00,0x01,0x01,0x01] 0x00 0x00 0x74 0xe0 0x00 0x01 0x01 0x01 +# VI: buffer_store_dwordx3 v[0:2], off, s[4:7], s0 offset:4095 ; encoding: [0xff,0x0f,0x78,0xe0,0x00,0x00,0x01,0x00] +0xff,0x0f,0x78,0xe0,0x00,0x00,0x01,0x00 + # VI: buffer_store_dwordx4 v[1:4], off, s[4:7], s1 ; encoding: [0x00,0x00,0x7c,0xe0,0x00,0x01,0x01,0x01] 0x00 0x00 0x7c 0xe0 0x00 0x01 0x01 0x01