Index: llvm/test/MC/Disassembler/AMDGPU/flat_gfx10.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/flat_gfx10.txt +++ /dev/null @@ -1,309 +0,0 @@ -# RUN: llvm-mc -arch=amdgcn -mcpu=gfx1010 -disassemble -show-encoding < %s | FileCheck %s - -#===------------------------------------------------------------------------===# -# scratch_load -#===------------------------------------------------------------------------===# - -# CHECK: scratch_load_dword v1, v255, off offset:-1 glc dlc ; encoding: [0xff,0x5f,0x31,0xdc,0xff,0x00,0x7d,0x01] -0xff 0x5f 0x31 0xdc 0xff 0x00 0x7d 0x01 - -# CHECK: scratch_load_dword v5, v255, off offset:-1 glc slc ; encoding: [0xff,0x4f,0x33,0xdc,0xff,0x00,0x7d,0x05] -0xff 0x4f 0x33 0xdc 0xff 0x00 0x7d 0x05 - -# CHECK: scratch_load_dword v0, v1, off offset:-2048 glc slc dlc ; encoding: [0x00,0x58,0x33,0xdc,0x01,0x00,0x7d,0x00] -0x00 0x58 0x33 0xdc 0x01 0x00 0x7d 0x00 - -# CHECK: scratch_load_dword v255, off, s105 offset:2047 dlc ; encoding: [0xff,0x57,0x30,0xdc,0x00,0x00,0x69,0xff] -0xff 0x57 0x30 0xdc 0x00 0x00 0x69 0xff - -# CHECK: scratch_load_dword v255, v2, off ; encoding: [0x00,0x40,0x30,0xdc,0x02,0x00,0x7d,0xff] -0x00 0x40 0x30 0xdc 0x02 0x00 0x7d 0xff - -# CHECK: scratch_load_dword v5, v0, off dlc ; encoding: [0x00,0x50,0x30,0xdc,0x00,0x00,0x7d,0x05] -0x00 0x50 0x30 0xdc 0x00 0x00 0x7d 0x05 - -# CHECK: scratch_load_dword v5, v3, off slc ; encoding: [0x00,0x40,0x32,0xdc,0x03,0x00,0x7d,0x05] -0x00 0x40 0x32 0xdc 0x03 0x00 0x7d 0x05 - -# CHECK: scratch_load_dword v5, v255, off slc dlc ; encoding: [0x00,0x50,0x32,0xdc,0xff,0x00,0x7d,0x05] -0x00 0x50 0x32 0xdc 0xff 0x00 0x7d 0x05 - -# CHECK: scratch_load_dword v255, off, s2 offset:1 ; encoding: [0x01,0x40,0x30,0xdc,0x00,0x00,0x02,0xff] -0x01 0x40 0x30 0xdc 0x00 0x00 0x02 0xff - -#===------------------------------------------------------------------------===# -# scratch_store -#===------------------------------------------------------------------------===# - -# CHECK: scratch_store_dword off, v2, s3 offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0x02,0x03,0x00] -0xff,0x4f,0x70,0xdc,0x00,0x02,0x03,0x00 - -# CHECK: scratch_store_dword off, v255, s3 offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0xff,0x03,0x00] -0xff,0x4f,0x70,0xdc,0x00,0xff,0x03,0x00 - -# CHECK: scratch_store_dword off, v2, s105 offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0x02,0x69,0x00] -0xff,0x4f,0x70,0xdc,0x00,0x02,0x69,0x00 - -# CHECK: scratch_store_dword off, v2, vcc_lo offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0x02,0x6a,0x00] -0xff,0x4f,0x70,0xdc,0x00,0x02,0x6a,0x00 - -# CHECK: scratch_store_dword off, v2, vcc_hi offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0x02,0x6b,0x00] -0xff,0x4f,0x70,0xdc,0x00,0x02,0x6b,0x00 - -# CHECK: scratch_store_dword off, v2, ttmp15 offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0x02,0x7b,0x00] -0xff,0x4f,0x70,0xdc,0x00,0x02,0x7b,0x00 - -# CHECK: scratch_store_dword v0, v2, off offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0x02,0x7d,0x00] -0xff,0x4f,0x70,0xdc,0x00,0x02,0x7d,0x00 - -# CHECK: scratch_store_dword off, v2, s3 ; encoding: [0x00,0x40,0x70,0xdc,0x00,0x02,0x03,0x00] -0x00,0x40,0x70,0xdc,0x00,0x02,0x03,0x00 - -# CHECK: scratch_store_dword off, v2, s3 offset:2047 ; encoding: [0xff,0x47,0x70,0xdc,0x00,0x02,0x03,0x00] -0xff,0x47,0x70,0xdc,0x00,0x02,0x03,0x00 - -# CHECK: scratch_store_dword off, v2, s3 offset:-2048 ; encoding: [0x00,0x48,0x70,0xdc,0x00,0x02,0x03,0x00] -0x00,0x48,0x70,0xdc,0x00,0x02,0x03,0x00 - -# CHECK: scratch_store_dword off, v2, s3 offset:-1 glc ; encoding: [0xff,0x4f,0x71,0xdc,0x00,0x02,0x03,0x00] -0xff,0x4f,0x71,0xdc,0x00,0x02,0x03,0x00 - -# CHECK: scratch_store_dword off, v2, s3 offset:-1 slc ; encoding: [0xff,0x4f,0x72,0xdc,0x00,0x02,0x03,0x00] -0xff,0x4f,0x72,0xdc,0x00,0x02,0x03,0x00 - -# CHECK: scratch_store_dword off, v2, s3 offset:-1 dlc ; encoding: [0xff,0x5f,0x70,0xdc,0x00,0x02,0x03,0x00] -0xff,0x5f,0x70,0xdc,0x00,0x02,0x03,0x00 - -#===------------------------------------------------------------------------===# -# FLAT opcodes: dlc support for atomics -#===------------------------------------------------------------------------===# - -# CHECK: flat_atomic_add v[1:2], v2 dlc ; encoding: [0x00,0x10,0xc8,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xc8,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_add_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x48,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x48,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_and v[1:2], v2 dlc ; encoding: [0x00,0x10,0xe4,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xe4,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_and_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x64,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x64,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_cmpswap v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0xc4,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xc4,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_cmpswap_x2 v[1:2], v[2:5] dlc ; encoding: [0x00,0x10,0x44,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x44,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_dec v[1:2], v2 dlc ; encoding: [0x00,0x10,0xf4,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xf4,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_dec_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x74,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x74,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_fcmpswap v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0xf8,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xf8,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_fcmpswap_x2 v[1:2], v[2:5] dlc ; encoding: [0x00,0x10,0x78,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x78,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_fmax v[1:2], v2 dlc ; encoding: [0x00,0x10,0x00,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x00,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_fmax_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x80,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x80,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_fmin v[1:2], v2 dlc ; encoding: [0x00,0x10,0xfc,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xfc,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_fmin_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x7c,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x7c,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_inc v[1:2], v2 dlc ; encoding: [0x00,0x10,0xf0,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xf0,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_inc_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x70,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x70,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_or v[1:2], v2 dlc ; encoding: [0x00,0x10,0xe8,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xe8,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_or_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x68,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x68,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_smax v[1:2], v2 dlc ; encoding: [0x00,0x10,0xdc,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xdc,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_smax_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x5c,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x5c,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_smin v[1:2], v2 dlc ; encoding: [0x00,0x10,0xd4,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xd4,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_smin_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x54,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x54,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_sub v[1:2], v2 dlc ; encoding: [0x00,0x10,0xcc,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xcc,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_sub_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x4c,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x4c,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_swap v[1:2], v2 dlc ; encoding: [0x00,0x10,0xc0,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xc0,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_swap_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x40,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x40,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_umax v[1:2], v2 dlc ; encoding: [0x00,0x10,0xe0,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xe0,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_umax_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x60,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x60,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_umin v[1:2], v2 dlc ; encoding: [0x00,0x10,0xd8,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xd8,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_umin_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x58,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x58,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_xor v[1:2], v2 dlc ; encoding: [0x00,0x10,0xec,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x10,0xec,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: flat_atomic_xor_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x6c,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x10,0x6c,0xdd,0x01,0x02,0x7d,0x00 - -#===------------------------------------------------------------------------===# -# FLAT GLOBAL opcodes: dlc support for atomics -#===------------------------------------------------------------------------===# - -# CHECK: global_atomic_add v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xc8,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xc8,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_add_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x48,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x48,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_and v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xe4,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xe4,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_and_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x64,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x64,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_cmpswap v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0xc4,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xc4,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_cmpswap_x2 v[1:2], v[2:5], off dlc ; encoding: [0x00,0x90,0x44,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x44,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_dec v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xf4,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xf4,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_dec_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x74,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x74,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fmax v[1:2], v2, off dlc ; encoding: [0x00,0x90,0x00,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x00,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fmax_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x80,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x80,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fmin v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xfc,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xfc,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fmin_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x7c,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x7c,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_inc v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xf0,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xf0,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_inc_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x70,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x70,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_or v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xe8,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xe8,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_or_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x68,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x68,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_smax v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xdc,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xdc,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_smax_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x5c,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x5c,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_smin v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xd4,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xd4,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_smin_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x54,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x54,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_sub v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xcc,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xcc,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_sub_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x4c,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x4c,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_swap v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xc0,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xc0,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_swap_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x40,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x40,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_umax v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xe0,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xe0,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_umax_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x60,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x60,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_umin v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xd8,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xd8,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_umin_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x58,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x58,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_xor v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xec,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x90,0xec,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_xor_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x6c,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x90,0x6c,0xdd,0x01,0x02,0x7d,0x00 - -#===------------------------------------------------------------------------===# -# FLAT GLOBAL opcodes: fcmpswap -#===------------------------------------------------------------------------===# - -# CHECK: global_atomic_fcmpswap v[1:2], v[2:3], off offset:-1 ; encoding: [0xff,0x8f,0xf8,0xdc,0x01,0x02,0x7d,0x00] -0xff,0x8f,0xf8,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fcmpswap v5, v[1:2], v[2:3], off offset:-1 glc ; encoding: [0xff,0x8f,0xf9,0xdc,0x01,0x02,0x7d,0x05] -0xff,0x8f,0xf9,0xdc,0x01,0x02,0x7d,0x05 - -# CHECK: global_atomic_fcmpswap v[1:2], v[2:3], off offset:2047 ; encoding: [0xff,0x87,0xf8,0xdc,0x01,0x02,0x7d,0x00] -0xff,0x87,0xf8,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fcmpswap v[1:2], v[2:3], off offset:-2048 ; encoding: [0x00,0x88,0xf8,0xdc,0x01,0x02,0x7d,0x00] -0x00,0x88,0xf8,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fcmpswap v[1:2], v[2:3], off offset:-1 slc ; encoding: [0xff,0x8f,0xfa,0xdc,0x01,0x02,0x7d,0x00] -0xff,0x8f,0xfa,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fcmpswap v[1:2], v[2:3], off offset:-1 dlc ; encoding: [0xff,0x9f,0xf8,0xdc,0x01,0x02,0x7d,0x00] -0xff,0x9f,0xf8,0xdc,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fcmpswap_x2 v[1:2], v[2:5], off offset:-1 ; encoding: [0xff,0x8f,0x78,0xdd,0x01,0x02,0x7d,0x00] -0xff,0x8f,0x78,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fcmpswap_x2 v[5:6], v[1:2], v[2:5], off offset:-1 glc ; encoding: [0xff,0x8f,0x79,0xdd,0x01,0x02,0x7d,0x05] -0xff,0x8f,0x79,0xdd,0x01,0x02,0x7d,0x05 - -# CHECK: global_atomic_fcmpswap_x2 v[1:2], v[2:5], off offset:2047 ; encoding: [0xff,0x87,0x78,0xdd,0x01,0x02,0x7d,0x00] -0xff,0x87,0x78,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fcmpswap_x2 v[1:2], v[2:5], off offset:-2048 ; encoding: [0x00,0x88,0x78,0xdd,0x01,0x02,0x7d,0x00] -0x00,0x88,0x78,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fcmpswap_x2 v[1:2], v[2:5], off offset:-1 slc ; encoding: [0xff,0x8f,0x7a,0xdd,0x01,0x02,0x7d,0x00] -0xff,0x8f,0x7a,0xdd,0x01,0x02,0x7d,0x00 - -# CHECK: global_atomic_fcmpswap_x2 v[1:2], v[2:5], off offset:-1 dlc ; encoding: [0xff,0x9f,0x78,0xdd,0x01,0x02,0x7d,0x00] -0xff,0x9f,0x78,0xdd,0x01,0x02,0x7d,0x00 Index: llvm/test/MC/Disassembler/AMDGPU/gfx10_flat.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/gfx10_flat.txt +++ llvm/test/MC/Disassembler/AMDGPU/gfx10_flat.txt @@ -2,6 +2,318 @@ # RUN: llvm-mc -arch=amdgcn -mcpu=gfx1010 -mattr=-wavefrontsize32,+wavefrontsize64 -disassemble -show-encoding < %s | FileCheck -strict-whitespace -check-prefix=GFX10 %s +#===------------------------------------------------------------------------===# +# scratch_load +#===------------------------------------------------------------------------===# + +# GFX10: scratch_load_dword v1, v255, off offset:-1 glc dlc ; encoding: [0xff,0x5f,0x31,0xdc,0xff,0x00,0x7d,0x01] +0xff 0x5f 0x31 0xdc 0xff 0x00 0x7d 0x01 + +# GFX10: scratch_load_dword v5, v255, off offset:-1 glc slc ; encoding: [0xff,0x4f,0x33,0xdc,0xff,0x00,0x7d,0x05] +0xff 0x4f 0x33 0xdc 0xff 0x00 0x7d 0x05 + +# GFX10: scratch_load_dword v0, v1, off offset:-2048 glc slc dlc ; encoding: [0x00,0x58,0x33,0xdc,0x01,0x00,0x7d,0x00] +0x00 0x58 0x33 0xdc 0x01 0x00 0x7d 0x00 + +# GFX10: scratch_load_dword v255, off, s105 offset:2047 dlc ; encoding: [0xff,0x57,0x30,0xdc,0x00,0x00,0x69,0xff] +0xff 0x57 0x30 0xdc 0x00 0x00 0x69 0xff + +# GFX10: scratch_load_dword v255, v2, off ; encoding: [0x00,0x40,0x30,0xdc,0x02,0x00,0x7d,0xff] +0x00 0x40 0x30 0xdc 0x02 0x00 0x7d 0xff + +# GFX10: scratch_load_dword v5, v0, off dlc ; encoding: [0x00,0x50,0x30,0xdc,0x00,0x00,0x7d,0x05] +0x00 0x50 0x30 0xdc 0x00 0x00 0x7d 0x05 + +# GFX10: scratch_load_dword v5, v3, off slc ; encoding: [0x00,0x40,0x32,0xdc,0x03,0x00,0x7d,0x05] +0x00 0x40 0x32 0xdc 0x03 0x00 0x7d 0x05 + +# GFX10: scratch_load_dword v5, v255, off slc dlc ; encoding: [0x00,0x50,0x32,0xdc,0xff,0x00,0x7d,0x05] +0x00 0x50 0x32 0xdc 0xff 0x00 0x7d 0x05 + +# GFX10: scratch_load_dword v255, off, s2 offset:1 ; encoding: [0x01,0x40,0x30,0xdc,0x00,0x00,0x02,0xff] +0x01 0x40 0x30 0xdc 0x00 0x00 0x02 0xff + +#===------------------------------------------------------------------------===# +# scratch_store +#===------------------------------------------------------------------------===# + +# GFX10: scratch_store_dword off, v2, s3 offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0x02,0x03,0x00] +0xff,0x4f,0x70,0xdc,0x00,0x02,0x03,0x00 + +# GFX10: scratch_store_dword off, v255, s3 offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0xff,0x03,0x00] +0xff,0x4f,0x70,0xdc,0x00,0xff,0x03,0x00 + +# GFX10: scratch_store_dword off, v2, s105 offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0x02,0x69,0x00] +0xff,0x4f,0x70,0xdc,0x00,0x02,0x69,0x00 + +# GFX10: scratch_store_dword off, v2, vcc_lo offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0x02,0x6a,0x00] +0xff,0x4f,0x70,0xdc,0x00,0x02,0x6a,0x00 + +# GFX10: scratch_store_dword off, v2, vcc_hi offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0x02,0x6b,0x00] +0xff,0x4f,0x70,0xdc,0x00,0x02,0x6b,0x00 + +# GFX10: scratch_store_dword off, v2, ttmp15 offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0x02,0x7b,0x00] +0xff,0x4f,0x70,0xdc,0x00,0x02,0x7b,0x00 + +# GFX10: scratch_store_dword v0, v2, off offset:-1 ; encoding: [0xff,0x4f,0x70,0xdc,0x00,0x02,0x7d,0x00] +0xff,0x4f,0x70,0xdc,0x00,0x02,0x7d,0x00 + +# GFX10: scratch_store_dword off, v2, s3 ; encoding: [0x00,0x40,0x70,0xdc,0x00,0x02,0x03,0x00] +0x00,0x40,0x70,0xdc,0x00,0x02,0x03,0x00 + +# GFX10: scratch_store_dword off, v2, s3 offset:2047 ; encoding: [0xff,0x47,0x70,0xdc,0x00,0x02,0x03,0x00] +0xff,0x47,0x70,0xdc,0x00,0x02,0x03,0x00 + +# GFX10: scratch_store_dword off, v2, s3 offset:-2048 ; encoding: [0x00,0x48,0x70,0xdc,0x00,0x02,0x03,0x00] +0x00,0x48,0x70,0xdc,0x00,0x02,0x03,0x00 + +# GFX10: scratch_store_dword off, v2, s3 offset:-1 glc ; encoding: [0xff,0x4f,0x71,0xdc,0x00,0x02,0x03,0x00] +0xff,0x4f,0x71,0xdc,0x00,0x02,0x03,0x00 + +# GFX10: scratch_store_dword off, v2, s3 offset:-1 slc ; encoding: [0xff,0x4f,0x72,0xdc,0x00,0x02,0x03,0x00] +0xff,0x4f,0x72,0xdc,0x00,0x02,0x03,0x00 + +# GFX10: scratch_store_dword off, v2, s3 offset:-1 dlc ; encoding: [0xff,0x5f,0x70,0xdc,0x00,0x02,0x03,0x00] +0xff,0x5f,0x70,0xdc,0x00,0x02,0x03,0x00 + +#===------------------------------------------------------------------------===# +# FLAT opcodes: dlc support for atomics +#===------------------------------------------------------------------------===# + +# GFX10: flat_atomic_add v[1:2], v2 dlc ; encoding: [0x00,0x10,0xc8,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xc8,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_add_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x48,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x48,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_and v[1:2], v2 dlc ; encoding: [0x00,0x10,0xe4,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xe4,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_and_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x64,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x64,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_cmpswap v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0xc4,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xc4,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_cmpswap_x2 v[1:2], v[2:5] dlc ; encoding: [0x00,0x10,0x44,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x44,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_dec v[1:2], v2 dlc ; encoding: [0x00,0x10,0xf4,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xf4,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_dec_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x74,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x74,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_fcmpswap v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0xf8,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xf8,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_fcmpswap_x2 v[1:2], v[2:5] dlc ; encoding: [0x00,0x10,0x78,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x78,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_fmax v[1:2], v2 dlc ; encoding: [0x00,0x10,0x00,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x00,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_fmax_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x80,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x80,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_fmin v[1:2], v2 dlc ; encoding: [0x00,0x10,0xfc,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xfc,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_fmin_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x7c,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x7c,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_inc v[1:2], v2 dlc ; encoding: [0x00,0x10,0xf0,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xf0,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_inc_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x70,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x70,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_or v[1:2], v2 dlc ; encoding: [0x00,0x10,0xe8,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xe8,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_or_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x68,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x68,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_smax v[1:2], v2 dlc ; encoding: [0x00,0x10,0xdc,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xdc,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_smax_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x5c,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x5c,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_smin v[1:2], v2 dlc ; encoding: [0x00,0x10,0xd4,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xd4,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_smin_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x54,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x54,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_sub v[1:2], v2 dlc ; encoding: [0x00,0x10,0xcc,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xcc,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_sub_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x4c,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x4c,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_swap v[1:2], v2 dlc ; encoding: [0x00,0x10,0xc0,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xc0,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_swap_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x40,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x40,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_umax v[1:2], v2 dlc ; encoding: [0x00,0x10,0xe0,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xe0,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_umax_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x60,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x60,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_umin v[1:2], v2 dlc ; encoding: [0x00,0x10,0xd8,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xd8,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_umin_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x58,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x58,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_xor v[1:2], v2 dlc ; encoding: [0x00,0x10,0xec,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x10,0xec,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: flat_atomic_xor_x2 v[1:2], v[2:3] dlc ; encoding: [0x00,0x10,0x6c,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x10,0x6c,0xdd,0x01,0x02,0x7d,0x00 + +#===------------------------------------------------------------------------===# +# FLAT GLOBAL opcodes: dlc support for atomics +#===------------------------------------------------------------------------===# + +# GFX10: global_atomic_add v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xc8,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xc8,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_add_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x48,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x48,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_and v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xe4,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xe4,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_and_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x64,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x64,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_cmpswap v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0xc4,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xc4,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_cmpswap_x2 v[1:2], v[2:5], off dlc ; encoding: [0x00,0x90,0x44,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x44,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_dec v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xf4,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xf4,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_dec_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x74,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x74,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fmax v[1:2], v2, off dlc ; encoding: [0x00,0x90,0x00,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x00,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fmax_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x80,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x80,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fmin v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xfc,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xfc,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fmin_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x7c,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x7c,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_inc v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xf0,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xf0,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_inc_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x70,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x70,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_or v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xe8,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xe8,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_or_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x68,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x68,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_smax v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xdc,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xdc,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_smax_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x5c,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x5c,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_smin v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xd4,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xd4,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_smin_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x54,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x54,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_sub v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xcc,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xcc,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_sub_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x4c,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x4c,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_swap v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xc0,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xc0,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_swap_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x40,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x40,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_umax v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xe0,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xe0,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_umax_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x60,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x60,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_umin v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xd8,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xd8,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_umin_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x58,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x58,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_xor v[1:2], v2, off dlc ; encoding: [0x00,0x90,0xec,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x90,0xec,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_xor_x2 v[1:2], v[2:3], off dlc ; encoding: [0x00,0x90,0x6c,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x90,0x6c,0xdd,0x01,0x02,0x7d,0x00 + +#===------------------------------------------------------------------------===# +# FLAT GLOBAL opcodes: fcmpswap +#===------------------------------------------------------------------------===# + +# GFX10: global_atomic_fcmpswap v[1:2], v[2:3], off offset:-1 ; encoding: [0xff,0x8f,0xf8,0xdc,0x01,0x02,0x7d,0x00] +0xff,0x8f,0xf8,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fcmpswap v5, v[1:2], v[2:3], off offset:-1 glc ; encoding: [0xff,0x8f,0xf9,0xdc,0x01,0x02,0x7d,0x05] +0xff,0x8f,0xf9,0xdc,0x01,0x02,0x7d,0x05 + +# GFX10: global_atomic_fcmpswap v[1:2], v[2:3], off offset:2047 ; encoding: [0xff,0x87,0xf8,0xdc,0x01,0x02,0x7d,0x00] +0xff,0x87,0xf8,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fcmpswap v[1:2], v[2:3], off offset:-2048 ; encoding: [0x00,0x88,0xf8,0xdc,0x01,0x02,0x7d,0x00] +0x00,0x88,0xf8,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fcmpswap v[1:2], v[2:3], off offset:-1 slc ; encoding: [0xff,0x8f,0xfa,0xdc,0x01,0x02,0x7d,0x00] +0xff,0x8f,0xfa,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fcmpswap v[1:2], v[2:3], off offset:-1 dlc ; encoding: [0xff,0x9f,0xf8,0xdc,0x01,0x02,0x7d,0x00] +0xff,0x9f,0xf8,0xdc,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fcmpswap_x2 v[1:2], v[2:5], off offset:-1 ; encoding: [0xff,0x8f,0x78,0xdd,0x01,0x02,0x7d,0x00] +0xff,0x8f,0x78,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fcmpswap_x2 v[5:6], v[1:2], v[2:5], off offset:-1 glc ; encoding: [0xff,0x8f,0x79,0xdd,0x01,0x02,0x7d,0x05] +0xff,0x8f,0x79,0xdd,0x01,0x02,0x7d,0x05 + +# GFX10: global_atomic_fcmpswap_x2 v[1:2], v[2:5], off offset:2047 ; encoding: [0xff,0x87,0x78,0xdd,0x01,0x02,0x7d,0x00] +0xff,0x87,0x78,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fcmpswap_x2 v[1:2], v[2:5], off offset:-2048 ; encoding: [0x00,0x88,0x78,0xdd,0x01,0x02,0x7d,0x00] +0x00,0x88,0x78,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fcmpswap_x2 v[1:2], v[2:5], off offset:-1 slc ; encoding: [0xff,0x8f,0x7a,0xdd,0x01,0x02,0x7d,0x00] +0xff,0x8f,0x7a,0xdd,0x01,0x02,0x7d,0x00 + +# GFX10: global_atomic_fcmpswap_x2 v[1:2], v[2:5], off offset:-1 dlc ; encoding: [0xff,0x9f,0x78,0xdd,0x01,0x02,0x7d,0x00] +0xff,0x9f,0x78,0xdd,0x01,0x02,0x7d,0x00 + +#===------------------------------------------------------------------------===# +# Other FLAT opcodes +#===------------------------------------------------------------------------===# + # GFX10: flat_atomic_add v[1:2], v2 ; encoding: [0x00,0x00,0xc8,0xdc,0x01,0x02,0x7d,0x00] 0x00,0x00,0xc8,0xdc,0x01,0x02,0x7d,0x00 Index: llvm/test/MC/Disassembler/AMDGPU/gfx10_mimg.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/gfx10_mimg.txt +++ llvm/test/MC/Disassembler/AMDGPU/gfx10_mimg.txt @@ -541,3 +541,229 @@ # GFX10: image_sample_c_cd_cl_o v[16:19], [v8, v9, v10, v11, v12, v13, v14], s[20:27], s[100:103] dmask:0xf dim:SQ_RSRC_IMG_1D_ARRAY ; encoding: [0x24,0x0f,0xbc,0xf1,0x08,0x10,0x25,0x03,0x09,0x0a,0x0b,0x0c,0x0d,0x0e,0x00,0x00] 0x24,0x0f,0xbc,0xf1,0x08,0x10,0x25,0x03,0x09,0x0a,0x0b,0x0c,0x0d,0x0e,0x0f,0x10 + +#===------------------------------------------------------------------------===# +# MIMG, Miscellaneous instructions +#===------------------------------------------------------------------------===# + +# GFX10: image_load v[4:6], v238, s[28:35] dmask:0x7 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x17,0x00,0xf0,0xee,0x04,0x07,0x00] +0x00,0x17,0x00,0xf0,0xee,0x04,0x07,0x00 + +# GFX10: image_load_pck v5, v0, s[8:15] dmask:0x1 dim:SQ_RSRC_IMG_1D glc ; encoding: [0x00,0x21,0x08,0xf0,0x00,0x05,0x02,0x00] +0x00,0x21,0x08,0xf0,0x00,0x05,0x02,0x00 + +# GFX10: image_load_pck_sgn v5, v0, s[8:15] dmask:0x1 dim:SQ_RSRC_IMG_1D lwe ; encoding: [0x00,0x01,0x0e,0xf0,0x00,0x05,0x02,0x00] +0x00,0x01,0x0e,0xf0,0x00,0x05,0x02,0x00 + +# GFX10: image_load_mip v5, v[0:1], s[8:15] dim:SQ_RSRC_IMG_1D ; encoding: [0x00,0x00,0x04,0xf0,0x00,0x05,0x02,0x00] +0x00,0x00,0x04,0xf0,0x00,0x05,0x02,0x00 + +# GFX10: image_load_mip_pck v5, v[1:2], s[8:15] dmask:0x1 dim:SQ_RSRC_IMG_1D ; encoding: [0x00,0x01,0x10,0xf0,0x01,0x05,0x02,0x00] +0x00,0x01,0x10,0xf0,0x01,0x05,0x02,0x00 + +# GFX10: image_load_mip_pck_sgn v[4:5], v[0:1], s[8:15] dmask:0x5 dim:SQ_RSRC_IMG_1D ; encoding: [0x00,0x05,0x14,0xf0,0x00,0x04,0x02,0x00] +0x00,0x05,0x14,0xf0,0x00,0x04,0x02,0x00 + +# GFX10: image_store v[192:194], v238, s[28:35] dmask:0x7 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x17,0x20,0xf0,0xee,0xc0,0x07,0x00] +0x00,0x17,0x20,0xf0,0xee,0xc0,0x07,0x00 + +# GFX10: image_store_pck v1, v2, s[12:19] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x28,0xf0,0x02,0x01,0x03,0x00] +0x00,0x51,0x28,0xf0,0x02,0x01,0x03,0x00 + +# GFX10: image_store_mip v1, v[2:3], s[12:19] dim:SQ_RSRC_IMG_1D ; encoding: [0x00,0x00,0x24,0xf0,0x02,0x01,0x03,0x00] +0x00,0x00,0x24,0xf0,0x02,0x01,0x03,0x00 + +# GFX10: image_store_mip_pck v252, v[2:3], s[12:19] dmask:0x1 dim:SQ_RSRC_IMG_1D r128 ; encoding: [0x00,0x81,0x2c,0xf0,0x02,0xfc,0x03,0x00] +0x00,0x81,0x2c,0xf0,0x02,0xfc,0x03,0x00 + +# GFX10: image_atomic_sub v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm glc ; encoding: [0x00,0x31,0x48,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x31,0x48,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_atomic_and v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x60,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x11,0x60,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_atomic_cmpswap v[4:5], v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm glc ; encoding: [0x00,0x31,0x40,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x31,0x40,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_atomic_add v[4:5], v192, s[28:35] dmask:0x3 dim:SQ_RSRC_IMG_1D unorm glc ; encoding: [0x00,0x33,0x44,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x33,0x44,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_atomic_or v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x64,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x11,0x64,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_atomic_xor v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x68,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x11,0x68,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_atomic_sub v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x48,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x11,0x48,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_atomic_smin v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x50,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x11,0x50,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_atomic_smax v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x58,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x11,0x58,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_atomic_umin v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x54,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x11,0x54,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_atomic_umax v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x5c,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x11,0x5c,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_atomic_inc v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x6c,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x11,0x6c,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_atomic_dec v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x70,0xf0,0xc0,0x04,0x07,0x00] +0x00,0x11,0x70,0xf0,0xc0,0x04,0x07,0x00 + +# GFX10: image_get_resinfo v5, v1, s[8:15] dmask:0x1 dim:SQ_RSRC_IMG_1D ; encoding: [0x00,0x01,0x38,0xf0,0x01,0x05,0x02,0x00] +0x00,0x01,0x38,0xf0,0x01,0x05,0x02,0x00 + +# GFX10: image_sample v5, v0, s[8:15], s[12:15] dmask:0x1 dim:SQ_RSRC_IMG_1D ; encoding: [0x00,0x01,0x80,0xf0,0x00,0x05,0x62,0x00] +0x00,0x01,0x80,0xf0,0x00,0x05,0x62,0x00 + +# GFX10: image_load v[0:3], v0, s[0:7] dmask:0xf dim:SQ_RSRC_IMG_2D unorm a16 ; encoding: [0x08,0x1f,0x00,0xf0,0x00,0x00,0x00,0x40] +0x08,0x1f,0x00,0xf0,0x00,0x00,0x00,0x40 + +# GFX10: image_load v[0:4], v[0:1], s[0:7] dmask:0xf dim:SQ_RSRC_IMG_2D unorm tfe ; encoding: [0x08,0x1f,0x01,0xf0,0x00,0x00,0x00,0x00] +0x08,0x1f,0x01,0xf0,0x00,0x00,0x00,0x00 + +# GFX10: image_load v[0:4], v0, s[0:7] dmask:0xf dim:SQ_RSRC_IMG_2D unorm a16 tfe ; encoding: [0x08,0x1f,0x01,0xf0,0x00,0x00,0x00,0x40] +0x08,0x1f,0x01,0xf0,0x00,0x00,0x00,0x40 + +# GFX10: image_load v1, v1, s[16:23] dmask:0x1 dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x08,0x01,0x00,0xf0,0x01,0x01,0x04,0x40] +0x08,0x01,0x00,0xf0,0x01,0x01,0x04,0x40 + +# GFX10: image_load v[1:2], v1, s[16:23] dmask:0x1 dim:SQ_RSRC_IMG_2D a16 tfe ; encoding: [0x08,0x01,0x01,0xf0,0x01,0x01,0x04,0x40] +0x08,0x01,0x01,0xf0,0x01,0x01,0x04,0x40 + +# GFX10: image_load v1, v1, s[16:23] dmask:0x1 dim:SQ_RSRC_IMG_2D a16 lwe ; encoding: [0x08,0x01,0x02,0xf0,0x01,0x01,0x04,0x40] +0x08,0x01,0x02,0xf0,0x01,0x01,0x04,0x40 + +# GFX10: image_load v[1:2], v1, s[16:23] dmask:0x1 dim:SQ_RSRC_IMG_2D a16 tfe lwe ; encoding: [0x08,0x01,0x03,0xf0,0x01,0x01,0x04,0x40] +0x08,0x01,0x03,0xf0,0x01,0x01,0x04,0x40 + +# GFX10: image_load v[1:2], v1, s[16:23] dmask:0x3 dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x08,0x03,0x00,0xf0,0x01,0x01,0x04,0x40] +0x08,0x03,0x00,0xf0,0x01,0x01,0x04,0x40 + +# GFX10: image_load v[1:4], v1, s[16:23] dmask:0x7 dim:SQ_RSRC_IMG_2D a16 tfe ; encoding: [0x08,0x07,0x01,0xf0,0x01,0x01,0x04,0x40] +0x08,0x07,0x01,0xf0,0x01,0x01,0x04,0x40 + +# GFX10: image_load v[1:4], v1, s[16:23] dmask:0xf dim:SQ_RSRC_IMG_2D a16 lwe ; encoding: [0x08,0x0f,0x02,0xf0,0x01,0x01,0x04,0x40] +0x08,0x0f,0x02,0xf0,0x01,0x01,0x04,0x40 + +# GFX10: image_load v[1:3], v1, s[16:23] dmask:0x5 dim:SQ_RSRC_IMG_2D a16 tfe lwe ; encoding: [0x08,0x05,0x03,0xf0,0x01,0x01,0x04,0x40] +0x08,0x05,0x03,0xf0,0x01,0x01,0x04,0x40 + +# GFX10: image_sample_d v[0:3], v[0:2], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0x88,0xf0,0x00,0x00,0x40,0x40] +0x00,0x0f,0x88,0xf0,0x00,0x00,0x40,0x40 + +# GFX10: image_sample_d v[0:3], v[0:4], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x08,0x0f,0x88,0xf0,0x00,0x00,0x40,0x40] +0x08,0x0f,0x88,0xf0,0x00,0x00,0x40,0x40 + +# GFX10: image_sample_d v[0:3], [v0, v1, v2, v3, v4, v5, v6, v8], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_3D a16 ; encoding: [0x14,0x0f,0x88,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x06,0x08,0x00] +0x14,0x0f,0x88,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x06,0x08,0x00 + +# GFX10: image_sample_c_d v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x40] +0x00,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x40 + +# GFX10: image_sample_c_d v[0:3], v[0:5], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x08,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x40] +0x08,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x40 + +# GFX10: image_sample_d_cl v[0:3], v[0:2], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x40] +0x00,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x40 + +# GFX10: image_sample_d_cl v[0:3], [v0, v1, v2, v3, v4, v6], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x0c,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x06,0x00,0x00,0x00] +0x0c,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x06,0x00,0x00,0x00 + +# GFX10: image_sample_c_d_cl v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0xac,0xf0,0x00,0x00,0x40,0x40] +0x00,0x0f,0xac,0xf0,0x00,0x00,0x40,0x40 + +# GFX10: image_sample_c_d_cl v[0:3], [v0, v1, v2, v3, v4, v5, v7], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x0c,0x0f,0xac,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x07,0x00,0x00] +0x0c,0x0f,0xac,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x07,0x00,0x00 + +# GFX10: image_sample_cd v[0:3], v[0:2], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x40] +0x00,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x40 + +# GFX10: image_sample_cd v[0:3], v[0:4], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x08,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x40] +0x08,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x40 + +# GFX10: image_sample_c_cd v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x40] +0x00,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x40 + +# GFX10: image_sample_c_cd v[0:3], v[0:5], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x08,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x40] +0x08,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x40 + +# GFX10: image_sample_cd_cl v[0:3], v[0:2], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x40] +0x00,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x40 + +# GFX10: image_sample_cd_cl v[0:3], [v0, v1, v2, v3, v4, v6], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x0c,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x06,0x00,0x00,0x00] +0x0c,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x06,0x00,0x00,0x00 + +# GFX10: image_sample_c_cd_cl v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0xac,0xf1,0x00,0x00,0x40,0x40] +0x00,0x0f,0xac,0xf1,0x00,0x00,0x40,0x40 + +# GFX10: image_sample_c_cd_cl v[0:3], [v0, v1, v2, v3, v4, v5, v7], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x0c,0x0f,0xac,0xf1,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x07,0x00,0x00] +0x0c,0x0f,0xac,0xf1,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x07,0x00,0x00 + +# GFX10: image_sample_c_d_o v0, [v0, v1, v2, v3, v4, v5, v6, v8], s[0:7], s[8:11] dmask:0x4 dim:SQ_RSRC_IMG_2D_ARRAY a16 ; encoding: [0x2c,0x04,0xe8,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x06,0x08,0x00] +0x2c,0x04,0xe8,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x06,0x08,0x00 + +# GFX10: image_sample_c_d_o v[0:1], [v0, v1, v2, v3, v4, v5, v6, v8], s[0:7], s[8:11] dmask:0x6 dim:SQ_RSRC_IMG_2D_ARRAY a16 ; encoding: [0x2c,0x06,0xe8,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x06,0x08,0x00] +0x2c,0x06,0xe8,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x06,0x08,0x00 + +# GFX10: image_sample_d_g16 v[0:3], v[0:2], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0x88,0xf0,0x00,0x00,0x40,0x00] +0x01,0x0f,0x88,0xf0,0x00,0x00,0x40,0x00 + +# GFX10: image_sample_d_g16 v[0:3], [v0, v2, v4, v5], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0b,0x0f,0x88,0xf0,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x00] +0x0b,0x0f,0x88,0xf0,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x00 + +# GFX10: image_sample_d_g16 v[0:3], [v0, v2, v3, v5, v6, v7, v8], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_3D ; encoding: [0x15,0x0f,0x88,0xf0,0x00,0x00,0x40,0x00,0x02,0x03,0x05,0x06,0x07,0x08,0x00,0x00] +0x15,0x0f,0x88,0xf0,0x00,0x00,0x40,0x00,0x02,0x03,0x05,0x06,0x07,0x08,0x00,0x00 + +# GFX10: image_sample_c_d_g16 v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x00] +0x01,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x00 + +# GFX10: image_sample_c_d_g16 v[0:3], [v0, v1, v3, v5, v6], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0b,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06] +0x0b,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06 + +# GFX10: image_sample_d_cl_g16 v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x00] +0x01,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x00 + +# GFX10: image_sample_d_cl_g16 v[0:3], [v0, v2, v4, v5, v6], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0b,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x06] +0x0b,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x06 + +# GFX10: image_sample_c_d_cl_g16 v[0:3], v[0:4], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0xac,0xf0,0x00,0x00,0x40,0x00] +0x01,0x0f,0xac,0xf0,0x00,0x00,0x40,0x00 + +# GFX10: image_sample_c_d_cl_g16 v[0:3], [v0, v1, v3, v5, v6, v7], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0d,0x0f,0xac,0xf0,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06,0x07,0x00,0x00,0x00] +0x0d,0x0f,0xac,0xf0,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06,0x07,0x00,0x00,0x00 + +# GFX10: image_sample_cd_g16 v[0:3], v[0:2], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x00] +0x01,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x00 + +# GFX10: image_sample_cd_g16 v[0:3], [v0, v2, v4, v5], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0b,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x00] +0x0b,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x00 + +# GFX10: image_sample_c_cd_g16 v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x00] +0x01,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x00 + +# GFX10: image_sample_c_cd_g16 v[0:3], [v0, v1, v3, v5, v6], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0b,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06] +0x0b,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06 + +# GFX10: image_sample_cd_cl_g16 v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x00] +0x01,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x00 + +# GFX10: image_sample_cd_cl_g16 v[0:3], [v0, v2, v4, v5, v6], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0b,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x06] +0x0b,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x06 + +# GFX10: image_sample_c_cd_cl_g16 v[0:3], v[0:4], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0xac,0xf1,0x00,0x00,0x40,0x00] +0x01,0x0f,0xac,0xf1,0x00,0x00,0x40,0x00 + +# GFX10: image_sample_c_cd_cl_g16 v[0:3], [v0, v1, v3, v5, v6, v7], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0d,0x0f,0xac,0xf1,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06,0x07,0x00,0x00,0x00] +0x0d,0x0f,0xac,0xf1,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06,0x07,0x00,0x00,0x00 + +# GFX10: image_sample_c_d_o_g16 v0, [v0, v1, v2, v4, v6, v7, v8], s[0:7], s[8:11] dmask:0x4 dim:SQ_RSRC_IMG_2D_ARRAY ; encoding: [0x2d,0x04,0xe8,0xf0,0x00,0x00,0x40,0x00,0x01,0x02,0x04,0x06,0x07,0x08,0x00,0x00] +0x2d,0x04,0xe8,0xf0,0x00,0x00,0x40,0x00,0x01,0x02,0x04,0x06,0x07,0x08,0x00,0x00 + +# GFX10: image_sample_c_d_o_g16 v[0:1], [v0, v1, v2, v4, v6, v7, v8], s[0:7], s[8:11] dmask:0x6 dim:SQ_RSRC_IMG_2D_ARRAY ; encoding: [0x2d,0x06,0xe8,0xf0,0x00,0x00,0x40,0x00,0x01,0x02,0x04,0x06,0x07,0x08,0x00,0x00] +0x2d,0x06,0xe8,0xf0,0x00,0x00,0x40,0x00,0x01,0x02,0x04,0x06,0x07,0x08,0x00,0x00 Index: llvm/test/MC/Disassembler/AMDGPU/gfx10_mubuf.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/gfx10_mubuf.txt +++ llvm/test/MC/Disassembler/AMDGPU/gfx10_mubuf.txt @@ -2284,3 +2284,33 @@ # GFX10: buffer_store_short v255, off, s[12:15], s4 offset:4095 ; encoding: [0xff,0x0f,0x68,0xe0,0x00,0xff,0x03,0x04] 0xff,0x0f,0x68,0xe0,0x00,0xff,0x03,0x04 + +# GFX10: buffer_atomic_fcmpswap v[5:6], off, s[8:11], s3 offset:4095 ; encoding: [0xff,0x0f,0xf8,0xe0,0x00,0x05,0x02,0x03] +0xff,0x0f,0xf8,0xe0,0x00,0x05,0x02,0x03 + +# GFX10: buffer_atomic_fcmpswap v[254:255], off, s[8:11], s3 offset:4095 ; encoding: [0xff,0x0f,0xf8,0xe0,0x00,0xfe,0x02,0x03] +0xff,0x0f,0xf8,0xe0,0x00,0xfe,0x02,0x03 + +# GFX10: buffer_atomic_fcmpswap_x2 v[5:8], off, s[8:11], s3 offset:7 ; encoding: [0x07,0x00,0x78,0xe1,0x00,0x05,0x02,0x03] +0x07,0x00,0x78,0xe1,0x00,0x05,0x02,0x03 + +# GFX10: buffer_atomic_fcmpswap_x2 v[5:8], off, s[8:11], s3 offset:4095 glc ; encoding: [0xff,0x4f,0x78,0xe1,0x00,0x05,0x02,0x03] +0xff,0x4f,0x78,0xe1,0x00,0x05,0x02,0x03 + +# GFX10: buffer_atomic_fmax v5, v0, s[8:11], s3 idxen offset:4095 ; encoding: [0xff,0x2f,0x00,0xe1,0x00,0x05,0x02,0x03] +0xff,0x2f,0x00,0xe1,0x00,0x05,0x02,0x03 + +# GFX10: buffer_atomic_fmax_x2 v[5:6], off, s[8:11], s3 offset:4095 glc ; encoding: [0xff,0x4f,0x80,0xe1,0x00,0x05,0x02,0x03] +0xff,0x4f,0x80,0xe1,0x00,0x05,0x02,0x03 + +# GFX10: buffer_atomic_fmax_x2 v[5:6], off, s[8:11], s3 offset:4095 slc ; encoding: [0xff,0x0f,0x80,0xe1,0x00,0x05,0x42,0x03] +0xff,0x0f,0x80,0xe1,0x00,0x05,0x42,0x03 + +# GFX10: buffer_atomic_fmin v5, off, s[8:11], s3 ; encoding: [0x00,0x00,0xfc,0xe0,0x00,0x05,0x02,0x03] +0x00,0x00,0xfc,0xe0,0x00,0x05,0x02,0x03 + +# GFX10: buffer_atomic_fmin v5, off, s[8:11], s3 offset:7 ; encoding: [0x07,0x00,0xfc,0xe0,0x00,0x05,0x02,0x03] +0x07,0x00,0xfc,0xe0,0x00,0x05,0x02,0x03 + +# GFX10: buffer_atomic_fmin_x2 v[5:6], off, ttmp[12:15], s3 offset:4095 ; encoding: [0xff,0x0f,0x7c,0xe1,0x00,0x05,0x1e,0x03] +0xff,0x0f,0x7c,0xe1,0x00,0x05,0x1e,0x03 Index: llvm/test/MC/Disassembler/AMDGPU/gfx10_sop2.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/gfx10_sop2.txt +++ llvm/test/MC/Disassembler/AMDGPU/gfx10_sop2.txt @@ -4972,3 +4972,9 @@ # GFX10: s_xor_b64 vcc, s[2:3], s[4:5] ; encoding: [0x02,0x04,0xea,0x89] 0x02,0x04,0xea,0x89 + +# GFX10: s_ashr_i64 s[0:1], null, s0 ; encoding: [0x7d,0x00,0x80,0x91] +0x7d,0x00,0x80,0x91 + +# GFX10: s_and_b64 s[0:1], null, null ; encoding: [0x7d,0x7d,0x80,0x87] +0x7d,0x7d,0x80,0x87 Index: llvm/test/MC/Disassembler/AMDGPU/gfx10_vop3cx.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/gfx10_vop3cx.txt +++ llvm/test/MC/Disassembler/AMDGPU/gfx10_vop3cx.txt @@ -7104,3 +7104,23 @@ # GFX10: v_cmpx_u_f64_e64 vcc, v[2:3] ; encoding: [0x7e,0x00,0x38,0xd4,0x6a,0x04,0x02,0x00] 0x7e,0x00,0x38,0xd4,0x6a,0x04,0x02,0x00 + +#===------------------------------------------------------------------------===# +# Regular v_cmpx encoding +#===------------------------------------------------------------------------===# + +# GFX10: v_cmpx_eq_f16_e64 s1, v2 +0x00,0x00,0xda,0xd4,0x01,0x04,0x02,0x00 + +# GFX10: v_cmpx_class_f32_e64 v0, 1 +0x00,0x00,0x98,0xd4,0x00,0x03,0x01,0x00 + +#===------------------------------------------------------------------------===# +# v_cmpx with arbitrary DST value should also be decodable +#===------------------------------------------------------------------------===# + +# GFX10: v_cmpx_eq_f16_e64 s1, v2 +0x7e,0x00,0xda,0xd4,0x01,0x04,0x02,0x00 + +# GFX10: v_cmpx_class_f32_e64 v0, 1 +0x7e,0x00,0x98,0xd4,0x00,0x03,0x01,0x00 Index: llvm/test/MC/Disassembler/AMDGPU/gfx10_vopc_sdwa.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/gfx10_vopc_sdwa.txt +++ llvm/test/MC/Disassembler/AMDGPU/gfx10_vopc_sdwa.txt @@ -114,6 +114,10 @@ # W64: v_cmp_class_f32_sdwa vcc, v1, v2 src0_sel:DWORD src1_sel:DWORD ; encoding: [0xf9,0x04,0x10,0x7d,0x01,0x00,0x06,0x06] 0xf9,0x04,0x10,0x7d,0x01,0x00,0x06,0x06 +# W32: v_cmp_class_f16_sdwa ttmp14, v1, v2 src0_sel:DWORD src1_sel:DWORD ; encoding: [0xf9,0x04,0x1e,0x7d,0x01,0xfa,0x06,0x06] +# W64: v_cmp_class_f16_sdwa ttmp[14:15], v1, v2 src0_sel:DWORD src1_sel:DWORD ; encoding: [0xf9,0x04,0x1e,0x7d,0x01,0xfa,0x06,0x06] +0xf9,0x04,0x1e,0x7d,0x01,0xfa,0x06,0x06 + # W32: v_cmp_eq_f16_sdwa s100, v1, v2 src0_sel:DWORD src1_sel:DWORD ; encoding: [0xf9,0x04,0x94,0x7d,0x01,0xe4,0x06,0x06] # W64: v_cmp_eq_f16_sdwa s[100:101], v1, v2 src0_sel:DWORD src1_sel:DWORD ; encoding: [0xf9,0x04,0x94,0x7d,0x01,0xe4,0x06,0x06] 0xf9,0x04,0x94,0x7d,0x01,0xe4,0x06,0x06 Index: llvm/test/MC/Disassembler/AMDGPU/gfx10_vopcx_sdwa.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/gfx10_vopcx_sdwa.txt +++ llvm/test/MC/Disassembler/AMDGPU/gfx10_vopcx_sdwa.txt @@ -4513,3 +4513,26 @@ # GFX10: v_cmpx_u_f32_sdwa |v1|, v2 src0_sel:DWORD src1_sel:DWORD ; encoding: [0xf9,0x04,0x30,0x7c,0x01,0x00,0x26,0x06] 0xf9,0x04,0x30,0x7c,0x01,0x00,0x26,0x06 + +#===------------------------------------------------------------------------===# +# Regular v_cmpx encoding +#===------------------------------------------------------------------------===# + +# GFX10: v_cmpx_eq_f16_sdwa -v1, v2 src0_sel:DWORD src1_sel:DWORD +0xf9,0x04,0xb4,0x7d,0x01,0x00,0x16,0x06 + +# GFX10: v_cmpx_class_f32_sdwa v0, 1 src0_sel:WORD_1 src1_sel:DWORD +0xf9,0x02,0x31,0x7d,0x00,0x00,0x05,0x86 + +#===------------------------------------------------------------------------===# +# v_cmpx with arbitrary DST value should also be decodable +#===------------------------------------------------------------------------===# + +# GFX10: v_cmpx_eq_f16_sdwa -v1, v2 src0_sel:DWORD src1_sel:DWORD +0xf9,0x04,0xb4,0x7d,0x01,0x7e,0x16,0x06 + +# GFX10: v_cmpx_class_f32_sdwa v0, 1 src0_sel:WORD_1 src1_sel:DWORD +0xf9,0x02,0x31,0x7d,0x00,0x7e,0x05,0x86 + +# GFX10: v_cmpx_class_f32_sdwa v0, 1 src0_sel:WORD_1 src1_sel:DWORD +0xf9,0x02,0x31,0x7d,0x00,0x7d,0x05,0x86 Index: llvm/test/MC/Disassembler/AMDGPU/mimg_gfx10.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/mimg_gfx10.txt +++ /dev/null @@ -1,223 +0,0 @@ -# RUN: llvm-mc -arch=amdgcn -mcpu=gfx1010 -disassemble -show-encoding < %s | FileCheck %s -check-prefix=GFX10 - -# GFX10: image_load v[4:6], v238, s[28:35] dmask:0x7 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x17,0x00,0xf0,0xee,0x04,0x07,0x00] -0x00,0x17,0x00,0xf0,0xee,0x04,0x07,0x00 - -# GFX10: image_load_pck v5, v0, s[8:15] dmask:0x1 dim:SQ_RSRC_IMG_1D glc ; encoding: [0x00,0x21,0x08,0xf0,0x00,0x05,0x02,0x00] -0x00,0x21,0x08,0xf0,0x00,0x05,0x02,0x00 - -# GFX10: image_load_pck_sgn v5, v0, s[8:15] dmask:0x1 dim:SQ_RSRC_IMG_1D lwe ; encoding: [0x00,0x01,0x0e,0xf0,0x00,0x05,0x02,0x00] -0x00,0x01,0x0e,0xf0,0x00,0x05,0x02,0x00 - -# GFX10: image_load_mip v5, v[0:1], s[8:15] dim:SQ_RSRC_IMG_1D ; encoding: [0x00,0x00,0x04,0xf0,0x00,0x05,0x02,0x00] -0x00,0x00,0x04,0xf0,0x00,0x05,0x02,0x00 - -# GFX10: image_load_mip_pck v5, v[1:2], s[8:15] dmask:0x1 dim:SQ_RSRC_IMG_1D ; encoding: [0x00,0x01,0x10,0xf0,0x01,0x05,0x02,0x00] -0x00,0x01,0x10,0xf0,0x01,0x05,0x02,0x00 - -# GFX10: image_load_mip_pck_sgn v[4:5], v[0:1], s[8:15] dmask:0x5 dim:SQ_RSRC_IMG_1D ; encoding: [0x00,0x05,0x14,0xf0,0x00,0x04,0x02,0x00] -0x00,0x05,0x14,0xf0,0x00,0x04,0x02,0x00 - -# GFX10: image_store v[192:194], v238, s[28:35] dmask:0x7 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x17,0x20,0xf0,0xee,0xc0,0x07,0x00] -0x00,0x17,0x20,0xf0,0xee,0xc0,0x07,0x00 - -# GFX10: image_store_pck v1, v2, s[12:19] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x28,0xf0,0x02,0x01,0x03,0x00] -0x00,0x51,0x28,0xf0,0x02,0x01,0x03,0x00 - -# GFX10: image_store_mip v1, v[2:3], s[12:19] dim:SQ_RSRC_IMG_1D ; encoding: [0x00,0x00,0x24,0xf0,0x02,0x01,0x03,0x00] -0x00,0x00,0x24,0xf0,0x02,0x01,0x03,0x00 - -# GFX10: image_store_mip_pck v252, v[2:3], s[12:19] dmask:0x1 dim:SQ_RSRC_IMG_1D r128 ; encoding: [0x00,0x81,0x2c,0xf0,0x02,0xfc,0x03,0x00] -0x00,0x81,0x2c,0xf0,0x02,0xfc,0x03,0x00 - -# GFX10: image_atomic_sub v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm glc ; encoding: [0x00,0x31,0x48,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x31,0x48,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_atomic_and v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x60,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x11,0x60,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_atomic_cmpswap v[4:5], v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm glc ; encoding: [0x00,0x31,0x40,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x31,0x40,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_atomic_add v[4:5], v192, s[28:35] dmask:0x3 dim:SQ_RSRC_IMG_1D unorm glc ; encoding: [0x00,0x33,0x44,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x33,0x44,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_atomic_or v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x64,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x11,0x64,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_atomic_xor v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x68,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x11,0x68,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_atomic_sub v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x48,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x11,0x48,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_atomic_smin v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x50,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x11,0x50,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_atomic_smax v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x58,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x11,0x58,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_atomic_umin v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x54,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x11,0x54,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_atomic_umax v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x5c,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x11,0x5c,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_atomic_inc v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x6c,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x11,0x6c,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_atomic_dec v4, v192, s[28:35] dmask:0x1 dim:SQ_RSRC_IMG_1D unorm ; encoding: [0x00,0x11,0x70,0xf0,0xc0,0x04,0x07,0x00] -0x00,0x11,0x70,0xf0,0xc0,0x04,0x07,0x00 - -# GFX10: image_get_resinfo v5, v1, s[8:15] dmask:0x1 dim:SQ_RSRC_IMG_1D ; encoding: [0x00,0x01,0x38,0xf0,0x01,0x05,0x02,0x00] -0x00,0x01,0x38,0xf0,0x01,0x05,0x02,0x00 - -# GFX10: image_sample v5, v0, s[8:15], s[12:15] dmask:0x1 dim:SQ_RSRC_IMG_1D ; encoding: [0x00,0x01,0x80,0xf0,0x00,0x05,0x62,0x00] -0x00,0x01,0x80,0xf0,0x00,0x05,0x62,0x00 - -# GFX10: image_load v[0:3], v0, s[0:7] dmask:0xf dim:SQ_RSRC_IMG_2D unorm a16 ; encoding: [0x08,0x1f,0x00,0xf0,0x00,0x00,0x00,0x40] -0x08,0x1f,0x00,0xf0,0x00,0x00,0x00,0x40 - -# GFX10: image_load v[0:4], v[0:1], s[0:7] dmask:0xf dim:SQ_RSRC_IMG_2D unorm tfe ; encoding: [0x08,0x1f,0x01,0xf0,0x00,0x00,0x00,0x00] -0x08,0x1f,0x01,0xf0,0x00,0x00,0x00,0x00 - -# GFX10: image_load v[0:4], v0, s[0:7] dmask:0xf dim:SQ_RSRC_IMG_2D unorm a16 tfe ; encoding: [0x08,0x1f,0x01,0xf0,0x00,0x00,0x00,0x40] -0x08,0x1f,0x01,0xf0,0x00,0x00,0x00,0x40 - -# GFX10: image_load v1, v1, s[16:23] dmask:0x1 dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x08,0x01,0x00,0xf0,0x01,0x01,0x04,0x40] -0x08,0x01,0x00,0xf0,0x01,0x01,0x04,0x40 - -# GFX10: image_load v[1:2], v1, s[16:23] dmask:0x1 dim:SQ_RSRC_IMG_2D a16 tfe ; encoding: [0x08,0x01,0x01,0xf0,0x01,0x01,0x04,0x40] -0x08,0x01,0x01,0xf0,0x01,0x01,0x04,0x40 - -# GFX10: image_load v1, v1, s[16:23] dmask:0x1 dim:SQ_RSRC_IMG_2D a16 lwe ; encoding: [0x08,0x01,0x02,0xf0,0x01,0x01,0x04,0x40] -0x08,0x01,0x02,0xf0,0x01,0x01,0x04,0x40 - -# GFX10: image_load v[1:2], v1, s[16:23] dmask:0x1 dim:SQ_RSRC_IMG_2D a16 tfe lwe ; encoding: [0x08,0x01,0x03,0xf0,0x01,0x01,0x04,0x40] -0x08,0x01,0x03,0xf0,0x01,0x01,0x04,0x40 - -# GFX10: image_load v[1:2], v1, s[16:23] dmask:0x3 dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x08,0x03,0x00,0xf0,0x01,0x01,0x04,0x40] -0x08,0x03,0x00,0xf0,0x01,0x01,0x04,0x40 - -# GFX10: image_load v[1:4], v1, s[16:23] dmask:0x7 dim:SQ_RSRC_IMG_2D a16 tfe ; encoding: [0x08,0x07,0x01,0xf0,0x01,0x01,0x04,0x40] -0x08,0x07,0x01,0xf0,0x01,0x01,0x04,0x40 - -# GFX10: image_load v[1:4], v1, s[16:23] dmask:0xf dim:SQ_RSRC_IMG_2D a16 lwe ; encoding: [0x08,0x0f,0x02,0xf0,0x01,0x01,0x04,0x40] -0x08,0x0f,0x02,0xf0,0x01,0x01,0x04,0x40 - -# GFX10: image_load v[1:3], v1, s[16:23] dmask:0x5 dim:SQ_RSRC_IMG_2D a16 tfe lwe ; encoding: [0x08,0x05,0x03,0xf0,0x01,0x01,0x04,0x40] -0x08,0x05,0x03,0xf0,0x01,0x01,0x04,0x40 - -# GFX10: image_sample_d v[0:3], v[0:2], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0x88,0xf0,0x00,0x00,0x40,0x40] -0x00,0x0f,0x88,0xf0,0x00,0x00,0x40,0x40 - -# GFX10: image_sample_d v[0:3], v[0:4], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x08,0x0f,0x88,0xf0,0x00,0x00,0x40,0x40] -0x08,0x0f,0x88,0xf0,0x00,0x00,0x40,0x40 - -# GFX10: image_sample_d v[0:3], [v0, v1, v2, v3, v4, v5, v6, v8], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_3D a16 ; encoding: [0x14,0x0f,0x88,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x06,0x08,0x00] -0x14,0x0f,0x88,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x06,0x08,0x00 - -# GFX10: image_sample_c_d v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x40] -0x00,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x40 - -# GFX10: image_sample_c_d v[0:3], v[0:5], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x08,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x40] -0x08,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x40 - -# GFX10: image_sample_d_cl v[0:3], v[0:2], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x40] -0x00,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x40 - -# GFX10: image_sample_d_cl v[0:3], [v0, v1, v2, v3, v4, v6], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x0c,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x06,0x00,0x00,0x00] -0x0c,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x06,0x00,0x00,0x00 - -# GFX10: image_sample_c_d_cl v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0xac,0xf0,0x00,0x00,0x40,0x40] -0x00,0x0f,0xac,0xf0,0x00,0x00,0x40,0x40 - -# GFX10: image_sample_c_d_cl v[0:3], [v0, v1, v2, v3, v4, v5, v7], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x0c,0x0f,0xac,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x07,0x00,0x00] -0x0c,0x0f,0xac,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x07,0x00,0x00 - -# GFX10: image_sample_cd v[0:3], v[0:2], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x40] -0x00,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x40 - -# GFX10: image_sample_cd v[0:3], v[0:4], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x08,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x40] -0x08,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x40 - -# GFX10: image_sample_c_cd v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x40] -0x00,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x40 - -# GFX10: image_sample_c_cd v[0:3], v[0:5], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x08,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x40] -0x08,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x40 - -# GFX10: image_sample_cd_cl v[0:3], v[0:2], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x40] -0x00,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x40 - -# GFX10: image_sample_cd_cl v[0:3], [v0, v1, v2, v3, v4, v6], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x0c,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x06,0x00,0x00,0x00] -0x0c,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x06,0x00,0x00,0x00 - -# GFX10: image_sample_c_cd_cl v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D a16 ; encoding: [0x00,0x0f,0xac,0xf1,0x00,0x00,0x40,0x40] -0x00,0x0f,0xac,0xf1,0x00,0x00,0x40,0x40 - -# GFX10: image_sample_c_cd_cl v[0:3], [v0, v1, v2, v3, v4, v5, v7], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D a16 ; encoding: [0x0c,0x0f,0xac,0xf1,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x07,0x00,0x00] -0x0c,0x0f,0xac,0xf1,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x07,0x00,0x00 - -# GFX10: image_sample_c_d_o v0, [v0, v1, v2, v3, v4, v5, v6, v8], s[0:7], s[8:11] dmask:0x4 dim:SQ_RSRC_IMG_2D_ARRAY a16 ; encoding: [0x2c,0x04,0xe8,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x06,0x08,0x00] -0x2c,0x04,0xe8,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x06,0x08,0x00 - -# GFX10: image_sample_c_d_o v[0:1], [v0, v1, v2, v3, v4, v5, v6, v8], s[0:7], s[8:11] dmask:0x6 dim:SQ_RSRC_IMG_2D_ARRAY a16 ; encoding: [0x2c,0x06,0xe8,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x06,0x08,0x00] -0x2c,0x06,0xe8,0xf0,0x00,0x00,0x40,0x40,0x01,0x02,0x03,0x04,0x05,0x06,0x08,0x00 - -# GFX10: image_sample_d_g16 v[0:3], v[0:2], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0x88,0xf0,0x00,0x00,0x40,0x00] -0x01,0x0f,0x88,0xf0,0x00,0x00,0x40,0x00 - -# GFX10: image_sample_d_g16 v[0:3], [v0, v2, v4, v5], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0b,0x0f,0x88,0xf0,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x00] -0x0b,0x0f,0x88,0xf0,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x00 - -# GFX10: image_sample_d_g16 v[0:3], [v0, v2, v3, v5, v6, v7, v8], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_3D ; encoding: [0x15,0x0f,0x88,0xf0,0x00,0x00,0x40,0x00,0x02,0x03,0x05,0x06,0x07,0x08,0x00,0x00] -0x15,0x0f,0x88,0xf0,0x00,0x00,0x40,0x00,0x02,0x03,0x05,0x06,0x07,0x08,0x00,0x00 - -# GFX10: image_sample_c_d_g16 v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x00] -0x01,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x00 - -# GFX10: image_sample_c_d_g16 v[0:3], [v0, v1, v3, v5, v6], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0b,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06] -0x0b,0x0f,0xa8,0xf0,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06 - -# GFX10: image_sample_d_cl_g16 v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x00] -0x01,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x00 - -# GFX10: image_sample_d_cl_g16 v[0:3], [v0, v2, v4, v5, v6], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0b,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x06] -0x0b,0x0f,0x8c,0xf0,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x06 - -# GFX10: image_sample_c_d_cl_g16 v[0:3], v[0:4], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0xac,0xf0,0x00,0x00,0x40,0x00] -0x01,0x0f,0xac,0xf0,0x00,0x00,0x40,0x00 - -# GFX10: image_sample_c_d_cl_g16 v[0:3], [v0, v1, v3, v5, v6, v7], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0d,0x0f,0xac,0xf0,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06,0x07,0x00,0x00,0x00] -0x0d,0x0f,0xac,0xf0,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06,0x07,0x00,0x00,0x00 - -# GFX10: image_sample_cd_g16 v[0:3], v[0:2], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x00] -0x01,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x00 - -# GFX10: image_sample_cd_g16 v[0:3], [v0, v2, v4, v5], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0b,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x00] -0x0b,0x0f,0xa0,0xf1,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x00 - -# GFX10: image_sample_c_cd_g16 v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x00] -0x01,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x00 - -# GFX10: image_sample_c_cd_g16 v[0:3], [v0, v1, v3, v5, v6], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0b,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06] -0x0b,0x0f,0xa8,0xf1,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06 - -# GFX10: image_sample_cd_cl_g16 v[0:3], v[0:3], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x00] -0x01,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x00 - -# GFX10: image_sample_cd_cl_g16 v[0:3], [v0, v2, v4, v5, v6], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0b,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x06] -0x0b,0x0f,0xa4,0xf1,0x00,0x00,0x40,0x00,0x02,0x04,0x05,0x06 - -# GFX10: image_sample_c_cd_cl_g16 v[0:3], v[0:4], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_1D ; encoding: [0x01,0x0f,0xac,0xf1,0x00,0x00,0x40,0x00] -0x01,0x0f,0xac,0xf1,0x00,0x00,0x40,0x00 - -# GFX10: image_sample_c_cd_cl_g16 v[0:3], [v0, v1, v3, v5, v6, v7], s[0:7], s[8:11] dmask:0xf dim:SQ_RSRC_IMG_2D ; encoding: [0x0d,0x0f,0xac,0xf1,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06,0x07,0x00,0x00,0x00] -0x0d,0x0f,0xac,0xf1,0x00,0x00,0x40,0x00,0x01,0x03,0x05,0x06,0x07,0x00,0x00,0x00 - -# GFX10: image_sample_c_d_o_g16 v0, [v0, v1, v2, v4, v6, v7, v8], s[0:7], s[8:11] dmask:0x4 dim:SQ_RSRC_IMG_2D_ARRAY ; encoding: [0x2d,0x04,0xe8,0xf0,0x00,0x00,0x40,0x00,0x01,0x02,0x04,0x06,0x07,0x08,0x00,0x00] -0x2d,0x04,0xe8,0xf0,0x00,0x00,0x40,0x00,0x01,0x02,0x04,0x06,0x07,0x08,0x00,0x00 - -# GFX10: image_sample_c_d_o_g16 v[0:1], [v0, v1, v2, v4, v6, v7, v8], s[0:7], s[8:11] dmask:0x6 dim:SQ_RSRC_IMG_2D_ARRAY ; encoding: [0x2d,0x06,0xe8,0xf0,0x00,0x00,0x40,0x00,0x01,0x02,0x04,0x06,0x07,0x08,0x00,0x00] -0x2d,0x06,0xe8,0xf0,0x00,0x00,0x40,0x00,0x01,0x02,0x04,0x06,0x07,0x08,0x00,0x00 Index: llvm/test/MC/Disassembler/AMDGPU/mubuf_gfx10.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/mubuf_gfx10.txt +++ /dev/null @@ -1,31 +0,0 @@ -# RUN: llvm-mc -arch=amdgcn -mcpu=gfx1010 -disassemble -show-encoding < %s | FileCheck %s - -# CHECK: buffer_atomic_fcmpswap v[5:6], off, s[8:11], s3 offset:4095 ; encoding: [0xff,0x0f,0xf8,0xe0,0x00,0x05,0x02,0x03] -0xff,0x0f,0xf8,0xe0,0x00,0x05,0x02,0x03 - -# CHECK: buffer_atomic_fcmpswap v[254:255], off, s[8:11], s3 offset:4095 ; encoding: [0xff,0x0f,0xf8,0xe0,0x00,0xfe,0x02,0x03] -0xff,0x0f,0xf8,0xe0,0x00,0xfe,0x02,0x03 - -# CHECK: buffer_atomic_fcmpswap_x2 v[5:8], off, s[8:11], s3 offset:7 ; encoding: [0x07,0x00,0x78,0xe1,0x00,0x05,0x02,0x03] -0x07,0x00,0x78,0xe1,0x00,0x05,0x02,0x03 - -# CHECK: buffer_atomic_fcmpswap_x2 v[5:8], off, s[8:11], s3 offset:4095 glc ; encoding: [0xff,0x4f,0x78,0xe1,0x00,0x05,0x02,0x03] -0xff,0x4f,0x78,0xe1,0x00,0x05,0x02,0x03 - -# CHECK: buffer_atomic_fmax v5, v0, s[8:11], s3 idxen offset:4095 ; encoding: [0xff,0x2f,0x00,0xe1,0x00,0x05,0x02,0x03] -0xff,0x2f,0x00,0xe1,0x00,0x05,0x02,0x03 - -# CHECK: buffer_atomic_fmax_x2 v[5:6], off, s[8:11], s3 offset:4095 glc ; encoding: [0xff,0x4f,0x80,0xe1,0x00,0x05,0x02,0x03] -0xff,0x4f,0x80,0xe1,0x00,0x05,0x02,0x03 - -# CHECK: buffer_atomic_fmax_x2 v[5:6], off, s[8:11], s3 offset:4095 slc ; encoding: [0xff,0x0f,0x80,0xe1,0x00,0x05,0x42,0x03] -0xff,0x0f,0x80,0xe1,0x00,0x05,0x42,0x03 - -# CHECK: buffer_atomic_fmin v5, off, s[8:11], s3 ; encoding: [0x00,0x00,0xfc,0xe0,0x00,0x05,0x02,0x03] -0x00,0x00,0xfc,0xe0,0x00,0x05,0x02,0x03 - -# CHECK: buffer_atomic_fmin v5, off, s[8:11], s3 offset:7 ; encoding: [0x07,0x00,0xfc,0xe0,0x00,0x05,0x02,0x03] -0x07,0x00,0xfc,0xe0,0x00,0x05,0x02,0x03 - -# CHECK: buffer_atomic_fmin_x2 v[5:6], off, ttmp[12:15], s3 offset:4095 ; encoding: [0xff,0x0f,0x7c,0xe1,0x00,0x05,0x1e,0x03] -0xff,0x0f,0x7c,0xe1,0x00,0x05,0x1e,0x03 Index: llvm/test/MC/Disassembler/AMDGPU/sop2_gfx10.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/sop2_gfx10.txt +++ /dev/null @@ -1,7 +0,0 @@ -# RUN: llvm-mc -arch=amdgcn -mcpu=gfx1010 -disassemble -show-encoding < %s | FileCheck %s -check-prefix=GFX10 - -# GFX10: s_ashr_i64 s[0:1], null, s0 ; encoding: [0x7d,0x00,0x80,0x91] -0x7d,0x00,0x80,0x91 - -# GFX10: s_and_b64 s[0:1], null, null ; encoding: [0x7d,0x7d,0x80,0x87] -0x7d,0x7d,0x80,0x87 Index: llvm/test/MC/Disassembler/AMDGPU/vcmp-gfx10.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/vcmp-gfx10.txt +++ /dev/null @@ -1,6 +0,0 @@ -# RUN: llvm-mc -arch=amdgcn -mcpu=gfx1010 -mattr=+wavefrontsize32,-wavefrontsize64 -disassemble -show-encoding < %s | FileCheck -check-prefix=W32 %s -# RUN: llvm-mc -arch=amdgcn -mcpu=gfx1010 -mattr=-wavefrontsize32,+wavefrontsize64 -disassemble -show-encoding < %s | FileCheck -check-prefix=W64 %s - -# W32: v_cmp_class_f16_sdwa ttmp14, v1, v2 src0_sel:DWORD src1_sel:DWORD ; encoding: [0xf9,0x04,0x1e,0x7d,0x01,0xfa,0x06,0x06] -# W64: v_cmp_class_f16_sdwa ttmp[14:15], v1, v2 src0_sel:DWORD src1_sel:DWORD ; encoding: [0xf9,0x04,0x1e,0x7d,0x01,0xfa,0x06,0x06] -0xf9,0x04,0x1e,0x7d,0x01,0xfa,0x06,0x06 Index: llvm/test/MC/Disassembler/AMDGPU/vcmpx-gfx10.txt =================================================================== --- llvm/test/MC/Disassembler/AMDGPU/vcmpx-gfx10.txt +++ /dev/null @@ -1,36 +0,0 @@ -# RUN: llvm-mc -arch=amdgcn -mcpu=gfx1010 -disassemble -show-encoding < %s | FileCheck -check-prefixes=GFX10 %s - -#===------------------------------------------------------------------------===# -# Regular v_cmpx encoding -#===------------------------------------------------------------------------===# - -# GFX10: v_cmpx_eq_f16_e64 s1, v2 -0x00,0x00,0xda,0xd4,0x01,0x04,0x02,0x00 - -# GFX10: v_cmpx_class_f32_e64 v0, 1 -0x00,0x00,0x98,0xd4,0x00,0x03,0x01,0x00 - -# GFX10: v_cmpx_eq_f16_sdwa -v1, v2 src0_sel:DWORD src1_sel:DWORD -0xf9,0x04,0xb4,0x7d,0x01,0x00,0x16,0x06 - -# GFX10: v_cmpx_class_f32_sdwa v0, 1 src0_sel:WORD_1 src1_sel:DWORD -0xf9,0x02,0x31,0x7d,0x00,0x00,0x05,0x86 - -#===------------------------------------------------------------------------===# -# v_cmpx with arbitrary DST value should also be decodable -#===------------------------------------------------------------------------===# - -# GFX10: v_cmpx_eq_f16_e64 s1, v2 -0x7e,0x00,0xda,0xd4,0x01,0x04,0x02,0x00 - -# GFX10: v_cmpx_class_f32_e64 v0, 1 -0x7e,0x00,0x98,0xd4,0x00,0x03,0x01,0x00 - -# GFX10: v_cmpx_eq_f16_sdwa -v1, v2 src0_sel:DWORD src1_sel:DWORD -0xf9,0x04,0xb4,0x7d,0x01,0x7e,0x16,0x06 - -# GFX10: v_cmpx_class_f32_sdwa v0, 1 src0_sel:WORD_1 src1_sel:DWORD -0xf9,0x02,0x31,0x7d,0x00,0x7e,0x05,0x86 - -# GFX10: v_cmpx_class_f32_sdwa v0, 1 src0_sel:WORD_1 src1_sel:DWORD -0xf9,0x02,0x31,0x7d,0x00,0x7d,0x05,0x86