diff --git a/llvm/test/MC/AMDGPU/gfx10_asm_sop.s b/llvm/test/MC/AMDGPU/gfx10_asm_sop.s --- a/llvm/test/MC/AMDGPU/gfx10_asm_sop.s +++ b/llvm/test/MC/AMDGPU/gfx10_asm_sop.s @@ -9816,6 +9816,12 @@ s_endpgm // GFX10: encoding: [0x00,0x00,0x81,0xbf] +s_endpgm 1 +// GFX10: encoding: [0x01,0x00,0x81,0xbf] + +s_endpgm 65535 +// GFX10: encoding: [0xff,0xff,0x81,0xbf] + s_branch 0x0 // GFX10: encoding: [0x00,0x00,0x82,0xbf] diff --git a/llvm/test/MC/AMDGPU/gfx11_asm_sopp.s b/llvm/test/MC/AMDGPU/gfx11_asm_sopp.s --- a/llvm/test/MC/AMDGPU/gfx11_asm_sopp.s +++ b/llvm/test/MC/AMDGPU/gfx11_asm_sopp.s @@ -215,6 +215,12 @@ s_endpgm // GFX11: s_endpgm ; encoding: [0x00,0x00,0xb0,0xbf] +s_endpgm 1 +// GFX11: s_endpgm 1 ; encoding: [0x01,0x00,0xb0,0xbf] + +s_endpgm 65535 +// GFX11: s_endpgm 65535 ; encoding: [0xff,0xff,0xb0,0xbf] + s_branch 0x0 // GFX11: s_branch 0 ; encoding: [0x00,0x00,0xa0,0xbf] diff --git a/llvm/test/MC/AMDGPU/gfx7_asm_sopp.s b/llvm/test/MC/AMDGPU/gfx7_asm_sopp.s --- a/llvm/test/MC/AMDGPU/gfx7_asm_sopp.s +++ b/llvm/test/MC/AMDGPU/gfx7_asm_sopp.s @@ -9,6 +9,12 @@ s_endpgm // CHECK: [0x00,0x00,0x81,0xbf] +s_endpgm 1 +// CHECK: [0x01,0x00,0x81,0xbf] + +s_endpgm 65535 +// CHECK: [0xff,0xff,0x81,0xbf] + s_branch 12609 // CHECK: [0x41,0x31,0x82,0xbf] diff --git a/llvm/test/MC/AMDGPU/gfx8_asm_sopp.s b/llvm/test/MC/AMDGPU/gfx8_asm_sopp.s --- a/llvm/test/MC/AMDGPU/gfx8_asm_sopp.s +++ b/llvm/test/MC/AMDGPU/gfx8_asm_sopp.s @@ -9,6 +9,12 @@ s_endpgm // CHECK: [0x00,0x00,0x81,0xbf] +s_endpgm 1 +// CHECK: [0x01,0x00,0x81,0xbf] + +s_endpgm 65535 +// CHECK: [0xff,0xff,0x81,0xbf] + s_branch 12609 // CHECK: [0x41,0x31,0x82,0xbf] diff --git a/llvm/test/MC/AMDGPU/gfx9_asm_sopp.s b/llvm/test/MC/AMDGPU/gfx9_asm_sopp.s --- a/llvm/test/MC/AMDGPU/gfx9_asm_sopp.s +++ b/llvm/test/MC/AMDGPU/gfx9_asm_sopp.s @@ -9,6 +9,12 @@ s_endpgm // CHECK: [0x00,0x00,0x81,0xbf] +s_endpgm 1 +// CHECK: [0x01,0x00,0x81,0xbf] + +s_endpgm 65535 +// CHECK: [0xff,0xff,0x81,0xbf] + s_branch 12609 // CHECK: [0x41,0x31,0x82,0xbf] diff --git a/llvm/test/MC/AMDGPU/sopp.s b/llvm/test/MC/AMDGPU/sopp.s --- a/llvm/test/MC/AMDGPU/sopp.s +++ b/llvm/test/MC/AMDGPU/sopp.s @@ -22,6 +22,12 @@ s_endpgm // GCN: s_endpgm ; encoding: [0x00,0x00,0x81,0xbf] +s_endpgm 1 +// GCN: s_endpgm 1 ; encoding: [0x01,0x00,0x81,0xbf] + +s_endpgm 65535 +// GCN: s_endpgm 65535 ; encoding: [0xff,0xff,0x81,0xbf] + s_branch 2 // GCN: s_branch 2 ; encoding: [0x02,0x00,0x82,0xbf] diff --git a/llvm/test/MC/Disassembler/AMDGPU/gfx10_sopp.txt b/llvm/test/MC/Disassembler/AMDGPU/gfx10_sopp.txt --- a/llvm/test/MC/Disassembler/AMDGPU/gfx10_sopp.txt +++ b/llvm/test/MC/Disassembler/AMDGPU/gfx10_sopp.txt @@ -137,6 +137,12 @@ # GFX10: s_endpgm ; encoding: [0x00,0x00,0x81,0xbf] 0x00,0x00,0x81,0xbf +# GFX10: s_endpgm 1 ; encoding: [0x01,0x00,0x81,0xbf] +0x01,0x00,0x81,0xbf + +# GFX10: s_endpgm 65535 ; encoding: [0xff,0xff,0x81,0xbf] +0xff,0xff,0x81,0xbf + # GFX10: s_endpgm_ordered_ps_done ; encoding: [0x00,0x00,0x9e,0xbf] 0x00,0x00,0x9e,0xbf diff --git a/llvm/test/MC/Disassembler/AMDGPU/gfx11_dasm_sopp.txt b/llvm/test/MC/Disassembler/AMDGPU/gfx11_dasm_sopp.txt --- a/llvm/test/MC/Disassembler/AMDGPU/gfx11_dasm_sopp.txt +++ b/llvm/test/MC/Disassembler/AMDGPU/gfx11_dasm_sopp.txt @@ -127,6 +127,12 @@ # GFX11: s_endpgm ; encoding: [0x00,0x00,0xb0,0xbf] 0x00,0x00,0xb0,0xbf +# GFX11: s_endpgm 1 ; encoding: [0x01,0x00,0xb0,0xbf] +0x01,0x00,0xb0,0xbf + +# GFX11: s_endpgm 65535 ; encoding: [0xff,0xff,0xb0,0xbf] +0xff,0xff,0xb0,0xbf + # GFX11: s_endpgm_saved ; encoding: [0x00,0x00,0xb1,0xbf] 0x00,0x00,0xb1,0xbf diff --git a/llvm/test/MC/Disassembler/AMDGPU/gfx8_sopp.txt b/llvm/test/MC/Disassembler/AMDGPU/gfx8_sopp.txt --- a/llvm/test/MC/Disassembler/AMDGPU/gfx8_sopp.txt +++ b/llvm/test/MC/Disassembler/AMDGPU/gfx8_sopp.txt @@ -9,6 +9,12 @@ # CHECK: s_endpgm ; encoding: [0x00,0x00,0x81,0xbf] 0x00,0x00,0x81,0xbf +# CHECK: s_endpgm 1 ; encoding: [0x01,0x00,0x81,0xbf] +0x01,0x00,0x81,0xbf + +# CHECK: s_endpgm 65535 ; encoding: [0xff,0xff,0x81,0xbf] +0xff,0xff,0x81,0xbf + # CHECK: s_branch 12609 ; encoding: [0x41,0x31,0x82,0xbf] 0x41,0x31,0x82,0xbf diff --git a/llvm/test/MC/Disassembler/AMDGPU/gfx9_sopp.txt b/llvm/test/MC/Disassembler/AMDGPU/gfx9_sopp.txt --- a/llvm/test/MC/Disassembler/AMDGPU/gfx9_sopp.txt +++ b/llvm/test/MC/Disassembler/AMDGPU/gfx9_sopp.txt @@ -9,6 +9,12 @@ # CHECK: s_endpgm ; encoding: [0x00,0x00,0x81,0xbf] 0x00,0x00,0x81,0xbf +# CHECK: s_endpgm 1 ; encoding: [0x01,0x00,0x81,0xbf] +0x01,0x00,0x81,0xbf + +# CHECK: s_endpgm 65535 ; encoding: [0xff,0xff,0x81,0xbf] +0xff,0xff,0x81,0xbf + # CHECK: s_branch 12609 ; encoding: [0x41,0x31,0x82,0xbf] 0x41,0x31,0x82,0xbf