[AMDGPU] Check for immediate SrcC in mfma in AsmParser
[llvm-core.git] / test / MC / AMDGPU / flat-global.s
blob0c9d4d0d77c6b4d752fc2e370139042e3d5fd1a7
1 // RUN: not llvm-mc -arch=amdgcn -mcpu=gfx900 -show-encoding %s | FileCheck -check-prefix=GFX9 -check-prefix=GCN %s
2 // RUN: not llvm-mc -arch=amdgcn -mcpu=gfx900 -show-encoding 2>&1 %s | FileCheck -check-prefix=GFX9-ERR -check-prefix=GCNERR %s
3 // RUN: not llvm-mc -arch=amdgcn -mcpu=tonga -show-encoding 2>&1 %s | FileCheck -check-prefix=VI-ERR -check-prefix=GCNERR %s
5 // RUN: not llvm-mc -arch=amdgcn -mcpu=gfx1010 -show-encoding %s | FileCheck --check-prefixes=GFX10 %s
6 // RUN: not llvm-mc -arch=amdgcn -mcpu=gfx1010 -show-encoding %s 2>&1 | FileCheck --check-prefixes=GFX10-ERR %s
8 global_load_ubyte v1, v[3:4], off
9 // GFX10: encoding: [0x00,0x80,0x20,0xdc,0x03,0x00,0x7d,0x01]
10 // GFX9: global_load_ubyte v1, v[3:4], off ; encoding: [0x00,0x80,0x40,0xdc,0x03,0x00,0x7f,0x01]
11 // VI-ERR: instruction not supported on this GPU
13 global_load_ubyte v1, v[3:4], off dlc
14 // GFX10: encoding: [0x00,0x90,0x20,0xdc,0x03,0x00,0x7d,0x01]
15 // GFX9-ERR: error: failed parsing operand
16 // VI-ERR: error: invalid operand for instruction
18 global_load_sbyte v1, v[3:4], off
19 // GFX10: encoding: [0x00,0x80,0x24,0xdc,0x03,0x00,0x7d,0x01]
20 // GFX9: global_load_sbyte v1, v[3:4], off ; encoding: [0x00,0x80,0x44,0xdc,0x03,0x00,0x7f,0x01]
21 // VI-ERR: instruction not supported on this GPU
23 global_load_sbyte v1, v[3:4], off dlc
24 // GFX10: encoding: [0x00,0x90,0x24,0xdc,0x03,0x00,0x7d,0x01]
25 // GFX9-ERR: error: failed parsing operand
26 // VI-ERR: error: invalid operand for instruction
28 global_load_ushort v1, v[3:4], off
29 // GFX10: encoding: [0x00,0x80,0x28,0xdc,0x03,0x00,0x7d,0x01]
30 // GFX9: global_load_ushort v1, v[3:4], off ; encoding: [0x00,0x80,0x48,0xdc,0x03,0x00,0x7f,0x01]
31 // VI-ERR: instruction not supported on this GPU
33 global_load_ushort v1, v[3:4], off dlc
34 // GFX10: encoding: [0x00,0x90,0x28,0xdc,0x03,0x00,0x7d,0x01]
35 // GFX9-ERR: error: failed parsing operand
36 // VI-ERR: error: invalid operand for instruction
38 global_load_sshort v1, v[3:4], off
39 // GFX10: encoding: [0x00,0x80,0x2c,0xdc,0x03,0x00,0x7d,0x01]
40 // GFX9: global_load_sshort v1, v[3:4], off ; encoding: [0x00,0x80,0x4c,0xdc,0x03,0x00,0x7f,0x01]
41 // VI-ERR: instruction not supported on this GPU
43 global_load_sshort v1, v[3:4], off dlc
44 // GFX10: encoding: [0x00,0x90,0x2c,0xdc,0x03,0x00,0x7d,0x01]
45 // GFX9-ERR: error: failed parsing operand
46 // VI-ERR: error: invalid operand for instruction
48 global_load_dword v1, v[3:4], off
49 // GFX10: encoding: [0x00,0x80,0x30,0xdc,0x03,0x00,0x7d,0x01]
50 // GFX9: global_load_dword v1, v[3:4], off ; encoding: [0x00,0x80,0x50,0xdc,0x03,0x00,0x7f,0x01]
51 // VI-ERR: instruction not supported on this GPU
53 global_load_dword v1, v[3:4], off dlc
54 // GFX10: encoding: [0x00,0x90,0x30,0xdc,0x03,0x00,0x7d,0x01]
55 // GFX9-ERR: error: failed parsing operand
56 // VI-ERR: error: invalid operand for instruction
58 global_load_dwordx2 v[1:2], v[3:4], off
59 // GFX10: encoding: [0x00,0x80,0x34,0xdc,0x03,0x00,0x7d,0x01]
60 // GFX9: global_load_dwordx2 v[1:2], v[3:4], off ; encoding: [0x00,0x80,0x54,0xdc,0x03,0x00,0x7f,0x01]
61 // VI-ERR: instruction not supported on this GPU
63 global_load_dwordx2 v[1:2], v[3:4], off dlc
64 // GFX10: encoding: [0x00,0x90,0x34,0xdc,0x03,0x00,0x7d,0x01]
65 // GFX9-ERR: error: failed parsing operand
66 // VI-ERR: error: invalid operand for instruction
68 global_load_dwordx3 v[1:3], v[3:4], off
69 // GFX10: encoding: [0x00,0x80,0x3c,0xdc,0x03,0x00,0x7d,0x01]
70 // GFX9: global_load_dwordx3 v[1:3], v[3:4], off ; encoding: [0x00,0x80,0x58,0xdc,0x03,0x00,0x7f,0x01]
71 // VI-ERR: instruction not supported on this GPU
73 global_load_dwordx3 v[1:3], v[3:4], off dlc
74 // GFX10: encoding: [0x00,0x90,0x3c,0xdc,0x03,0x00,0x7d,0x01]
75 // GFX9-ERR: error: failed parsing operand
76 // VI-ERR: error: invalid operand for instruction
78 global_load_dwordx4 v[1:4], v[3:4], off
79 // GFX10: encoding: [0x00,0x80,0x38,0xdc,0x03,0x00,0x7d,0x01]
80 // GFX9: global_load_dwordx4 v[1:4], v[3:4], off ; encoding: [0x00,0x80,0x5c,0xdc,0x03,0x00,0x7f,0x01]
81 // VI-ERR: instruction not supported on this GPU
83 global_load_dwordx4 v[1:4], v[3:4], off dlc
84 // GFX10: encoding: [0x00,0x90,0x38,0xdc,0x03,0x00,0x7d,0x01]
85 // GFX9-ERR: error: failed parsing operand
86 // VI-ERR: error: invalid operand for instruction
88 // FIXME: VI error should be instruction nto supported
89 global_load_dword v1, v[3:4], off offset:0
90 // GFX10: encoding: [0x00,0x80,0x30,0xdc,0x03,0x00,0x7d,0x01]
91 // GFX9: global_load_dword v1, v[3:4], off ; encoding: [0x00,0x80,0x50,0xdc,0x03,0x00,0x7f,0x01]
92 // VI-ERR: :35: error: not a valid operand.
94 global_load_dword v1, v[3:4], off offset:4095
95 // GFX10-ERR: :35: error: expected a 12-bit signed offset
96 // GFX9: global_load_dword v1, v[3:4], off offset:4095 ; encoding: [0xff,0x8f,0x50,0xdc,0x03,0x00,0x7f,0x01]
97 // VI-ERR: :35: error: not a valid operand.
99 global_load_dword v1, v[3:4], off offset:-1
100 // GFX10: encoding: [0xff,0x8f,0x30,0xdc,0x03,0x00,0x7d,0x01]
101 // GFX9: global_load_dword v1, v[3:4], off offset:-1 ; encoding: [0xff,0x9f,0x50,0xdc,0x03,0x00,0x7f,0x01]
102 // VI-ERR: :35: error: not a valid operand.
104 global_load_dword v1, v[3:4], off offset:-4096
105 // GFX10-ERR: :35: error: expected a 12-bit signed offset
106 // GFX9: global_load_dword v1, v[3:4], off offset:-4096 ; encoding: [0x00,0x90,0x50,0xdc,0x03,0x00,0x7f,0x01]
107 // VI-ERR: :35: error: not a valid operand.
109 global_load_dword v1, v[3:4], off offset:4096
110 // GFX10-ERR: :35: error: expected a 12-bit signed offset
111 // GFX9-ERR: :35: error: expected a 13-bit signed offset
112 // VI-ERR: :35: error: not a valid operand.
114 global_load_dword v1, v[3:4] off, offset:-4097
115 // GFX10-ERR: :35: error: expected a 12-bit signed offset
116 // GFX9-ERR: :35: error: expected a 13-bit signed offset
117 // VI-ERR: :35: error: not a valid operand.
119 global_store_byte v[3:4], v1, off
120 // GFX10: encoding: [0x00,0x80,0x60,0xdc,0x03,0x01,0x7d,0x00]
121 // GFX9: global_store_byte v[3:4], v1, off ; encoding: [0x00,0x80,0x60,0xdc,0x03,0x01,0x7f,0x00]
122 // VI-ERR: instruction not supported on this GPU
124 global_store_byte v[3:4], v1, off dlc
125 // GFX10: encoding: [0x00,0x90,0x60,0xdc,0x03,0x01,0x7d,0x00]
126 // GFX9-ERR: error: failed parsing operand
127 // VI-ERR: error: invalid operand for instruction
129 global_store_short v[3:4], v1, off
130 // GFX10: encoding: [0x00,0x80,0x68,0xdc,0x03,0x01,0x7d,0x00]
131 // GFX9: global_store_short v[3:4], v1, off ; encoding: [0x00,0x80,0x68,0xdc,0x03,0x01,0x7f,0x00]
132 // VI-ERR: instruction not supported on this GPU
134 global_store_short v[3:4], v1, off dlc
135 // GFX10: encoding: [0x00,0x90,0x68,0xdc,0x03,0x01,0x7d,0x00]
136 // GFX9-ERR: error: failed parsing operand
137 // VI-ERR: error: invalid operand for instruction
139 global_store_dword v[3:4], v1, off
140 // GFX10: encoding: [0x00,0x80,0x70,0xdc,0x03,0x01,0x7d,0x00]
141 // GFX9: global_store_dword v[3:4], v1, off ; encoding: [0x00,0x80,0x70,0xdc,0x03,0x01,0x7f,0x00]
142 // VI-ERR: instruction not supported on this GPU
144 global_store_dword v[3:4], v1, off dlc
145 // GFX10: encoding: [0x00,0x90,0x70,0xdc,0x03,0x01,0x7d,0x00]
146 // GFX9-ERR: error: failed parsing operand
147 // VI-ERR: error: invalid operand for instruction
149 global_store_dwordx2 v[3:4], v[1:2], off
150 // GFX10: encoding: [0x00,0x80,0x74,0xdc,0x03,0x01,0x7d,0x00]
151 // GFX9: global_store_dwordx2 v[3:4], v[1:2], off ; encoding: [0x00,0x80,0x74,0xdc,0x03,0x01,0x7f,0x00]
152 // VI-ERR: instruction not supported on this GPU
154 global_store_dwordx2 v[3:4], v[1:2], off dlc
155 // GFX10: encoding: [0x00,0x90,0x74,0xdc,0x03,0x01,0x7d,0x00]
156 // GFX9-ERR: error: failed parsing operand
157 // VI-ERR: error: invalid operand for instruction
159 global_store_dwordx3 v[3:4], v[1:3], off
160 // GFX10: encoding: [0x00,0x80,0x7c,0xdc,0x03,0x01,0x7d,0x00]
161 // GFX9: global_store_dwordx3 v[3:4], v[1:3], off ; encoding: [0x00,0x80,0x78,0xdc,0x03,0x01,0x7f,0x00]
162 // VI-ERR: instruction not supported on this GPU
164 global_store_dwordx3 v[3:4], v[1:3], off dlc
165 // GFX10: encoding: [0x00,0x90,0x7c,0xdc,0x03,0x01,0x7d,0x00]
166 // GFX9-ERR: error: failed parsing operand
167 // VI-ERR: error: invalid operand for instruction
169 global_store_dwordx4 v[3:4], v[1:4], off
170 // GFX10: encoding: [0x00,0x80,0x78,0xdc,0x03,0x01,0x7d,0x00]
171 // GFX9: global_store_dwordx4 v[3:4], v[1:4], off ; encoding: [0x00,0x80,0x7c,0xdc,0x03,0x01,0x7f,0x00]
172 // VI-ERR: instruction not supported on this GPU
174 global_store_dwordx4 v[3:4], v[1:4], off dlc
175 // GFX10: encoding: [0x00,0x90,0x78,0xdc,0x03,0x01,0x7d,0x00]
176 // GFX9-ERR: error: failed parsing operand
177 // VI-ERR: error: invalid operand for instruction
179 global_store_dword v[3:4], v1, off offset:12
180 // GFX10: encoding: [0x0c,0x80,0x70,0xdc,0x03,0x01,0x7d,0x00]
181 // GFX9: global_store_dword v[3:4], v1, off offset:12 ; encoding: [0x0c,0x80,0x70,0xdc,0x03,0x01,0x7f,0x00]
182 // VI-ERR: :36: error: not a valid operand
184 global_load_dword v1, v[3:4], s[2:3]
185 // GFX10: encoding: [0x00,0x80,0x30,0xdc,0x03,0x00,0x02,0x01]
186 // GFX9: global_load_dword v1, v[3:4], s[2:3] ; encoding: [0x00,0x80,0x50,0xdc,0x03,0x00,0x02,0x01]
187 // VI-ERR: instruction not supported on this GPU
189 global_load_dword v1, v[3:4], s[2:3] offset:24
190 // GFX10: encoding: [0x18,0x80,0x30,0xdc,0x03,0x00,0x02,0x01]
191 // GFX9: global_load_dword v1, v[3:4], s[2:3] offset:24 ; encoding: [0x18,0x80,0x50,0xdc,0x03,0x00,0x02,0x01]
192 // VI-ERR: :38: error: not a valid operand.
194 global_load_dword v1, v[3:4], s[2:3] offset:-8
195 // GFX10: encoding: [0xf8,0x8f,0x30,0xdc,0x03,0x00,0x02,0x01]
196 // GFX9: global_load_dword v1, v[3:4], s[2:3] offset:-8 ; encoding: [0xf8,0x9f,0x50,0xdc,0x03,0x00,0x02,0x01]
197 // VI-ERR: :38: error: not a valid operand.
199 global_store_dword v[3:4], v1, s[2:3]
200 // GFX10: encoding: [0x00,0x80,0x70,0xdc,0x03,0x01,0x02,0x00]
201 // GFX9: global_store_dword v[3:4], v1, s[2:3] ; encoding: [0x00,0x80,0x70,0xdc,0x03,0x01,0x02,0x00]
202 // VI-ERR: instruction not supported on this GPU
204 global_store_dword v[3:4], v1, s[2:3] offset:24
205 // GFX10: encoding: [0x18,0x80,0x70,0xdc,0x03,0x01,0x02,0x00]
206 // GFX9: global_store_dword v[3:4], v1, s[2:3] offset:24 ; encoding: [0x18,0x80,0x70,0xdc,0x03,0x01,0x02,0x00]
207 // VI-ERR: :39: error: not a valid operand.
209 global_store_dword v[3:4], v1, s[2:3] offset:-8
210 // GFX10: encoding: [0xf8,0x8f,0x70,0xdc,0x03,0x01,0x02,0x00]
211 // GFX9: global_store_dword v[3:4], v1, s[2:3] offset:-8 ; encoding: [0xf8,0x9f,0x70,0xdc,0x03,0x01,0x02,0x00]
212 // VI-ERR: :39: error: not a valid operand.
214 // XXX: Is this valid?
215 global_store_dword v[3:4], v1, exec
216 // GFX10: encoding: [0x00,0x80,0x70,0xdc,0x03,0x01,0x7e,0x00]
217 // GFX9: global_store_dword v[3:4], v1, exec ; encoding: [0x00,0x80,0x70,0xdc,0x03,0x01,0x7e,0x00]
218 // VI-ERR: instruction not supported on this GPU
220 global_load_dword v1, v[3:4], s2
221 // GFX10-ERR: error: invalid operand for instruction
222 // GFX9-ERR: :31: error: invalid operand for instruction
223 // VI-ERR: :31: error: invalid operand for instruction
225 global_load_dword v1, v[3:4], exec_hi
226 // GFX10-ERR: error: invalid operand for instruction
227 // GFX9-ERR: :31: error: invalid operand for instruction
228 // VI-ERR: :31: error: invalid operand for instruction
230 global_atomic_cmpswap v[3:4], v[5:6], off
231 // GFX10: encoding: [0x00,0x80,0xc4,0xdc,0x03,0x05,0x7d,0x00]
232 // GFX9: global_atomic_cmpswap v[3:4], v[5:6], off ; encoding: [0x00,0x80,0x04,0xdd,0x03,0x05,0x7f,0x00]
233 // VI-ERR: error: instruction not supported on this GPU
235 global_atomic_cmpswap_x2 v[3:4], v[5:8], off
236 // GFX10: encoding: [0x00,0x80,0x44,0xdd,0x03,0x05,0x7d,0x00]
237 // GFX9: global_atomic_cmpswap_x2 v[3:4], v[5:8], off ; encoding: [0x00,0x80,0x84,0xdd,0x03,0x05,0x7f,0x00]
238 // VI-ERR: error: instruction not supported on this GPU
240 global_atomic_swap v[3:4], v5, off
241 // GFX10: encoding: [0x00,0x80,0xc0,0xdc,0x03,0x05,0x7d,0x00]
242 // GFX9: global_atomic_swap v[3:4], v5, off ; encoding: [0x00,0x80,0x00,0xdd,0x03,0x05,0x7f,0x00]
243 // VI-ERR: error: instruction not supported on this GPU
245 global_atomic_swap_x2 v[3:4], v[5:6], off
246 // GFX10: encoding: [0x00,0x80,0x40,0xdd,0x03,0x05,0x7d,0x00]
247 // GFX9: global_atomic_swap_x2 v[3:4], v[5:6], off ; encoding: [0x00,0x80,0x80,0xdd,0x03,0x05,0x7f,0x00]
248 // VI-ERR: error: instruction not supported on this GPU
250 global_atomic_add v[3:4], v5, off
251 // GFX10: encoding: [0x00,0x80,0xc8,0xdc,0x03,0x05,0x7d,0x00]
252 // GFX9: global_atomic_add v[3:4], v5, off ; encoding: [0x00,0x80,0x08,0xdd,0x03,0x05,0x7f,0x00]
253 // VI-ERR: instruction not supported on this GPU
255 global_atomic_sub v[3:4], v5, off
256 // GFX10: encoding: [0x00,0x80,0xcc,0xdc,0x03,0x05,0x7d,0x00]
257 // GFX9: global_atomic_sub v[3:4], v5, off ; encoding: [0x00,0x80,0x0c,0xdd,0x03,0x05,0x7f,0x00]
258 // VI-ERR: instruction not supported on this GPU
260 global_atomic_smin v[3:4], v5, off
261 // GFX10: encoding: [0x00,0x80,0xd4,0xdc,0x03,0x05,0x7d,0x00]
262 // GFX9: global_atomic_smin v[3:4], v5, off ; encoding: [0x00,0x80,0x10,0xdd,0x03,0x05,0x7f,0x00]
263 // VI-ERR: instruction not supported on this GPU
265 global_atomic_umin v[3:4], v5, off
266 // GFX10: encoding: [0x00,0x80,0xd8,0xdc,0x03,0x05,0x7d,0x00]
267 // GFX9: global_atomic_umin v[3:4], v5, off ; encoding: [0x00,0x80,0x14,0xdd,0x03,0x05,0x7f,0x00]
268 // VI-ERR: instruction not supported on this GPU
270 global_atomic_smax v[3:4], v5, off
271 // GFX10: encoding: [0x00,0x80,0xdc,0xdc,0x03,0x05,0x7d,0x00]
272 // GFX9: global_atomic_smax v[3:4], v5, off ; encoding: [0x00,0x80,0x18,0xdd,0x03,0x05,0x7f,0x00]
273 // VI-ERR: instruction not supported on this GPU
275 global_atomic_umax v[3:4], v5, off
276 // GFX10: encoding: [0x00,0x80,0xe0,0xdc,0x03,0x05,0x7d,0x00]
277 // GFX9: global_atomic_umax v[3:4], v5, off ; encoding: [0x00,0x80,0x1c,0xdd,0x03,0x05,0x7f,0x00]
278 // VI-ERR: instruction not supported on this GPU
280 global_atomic_and v[3:4], v5, off
281 // GFX10: encoding: [0x00,0x80,0xe4,0xdc,0x03,0x05,0x7d,0x00]
282 // GFX9: global_atomic_and v[3:4], v5, off ; encoding: [0x00,0x80,0x20,0xdd,0x03,0x05,0x7f,0x00]
283 // VI-ERR: instruction not supported on this GPU
285 global_atomic_or v[3:4], v5, off
286 // GFX10: encoding: [0x00,0x80,0xe8,0xdc,0x03,0x05,0x7d,0x00]
287 // GFX9: global_atomic_or v[3:4], v5, off ; encoding: [0x00,0x80,0x24,0xdd,0x03,0x05,0x7f,0x00]
288 // VI-ERR: instruction not supported on this GPU
290 global_atomic_xor v[3:4], v5, off
291 // GFX10: encoding: [0x00,0x80,0xec,0xdc,0x03,0x05,0x7d,0x00]
292 // GFX9: global_atomic_xor v[3:4], v5, off ; encoding: [0x00,0x80,0x28,0xdd,0x03,0x05,0x7f,0x00]
293 // VI-ERR: instruction not supported on this GPU
295 global_atomic_inc v[3:4], v5, off
296 // GFX10: encoding: [0x00,0x80,0xf0,0xdc,0x03,0x05,0x7d,0x00]
297 // GFX9: global_atomic_inc v[3:4], v5, off ; encoding: [0x00,0x80,0x2c,0xdd,0x03,0x05,0x7f,0x00]
298 // VI-ERR: instruction not supported on this GPU
300 global_atomic_dec v[3:4], v5, off
301 // GFX10: encoding: [0x00,0x80,0xf4,0xdc,0x03,0x05,0x7d,0x00]
302 // GFX9: global_atomic_dec v[3:4], v5, off ; encoding: [0x00,0x80,0x30,0xdd,0x03,0x05,0x7f,0x00]
303 // VI-ERR: instruction not supported on this GPU
305 global_atomic_add_x2 v[3:4], v[5:6], off
306 // GFX10: encoding: [0x00,0x80,0x48,0xdd,0x03,0x05,0x7d,0x00]
307 // GFX9: global_atomic_add_x2 v[3:4], v[5:6], off ; encoding: [0x00,0x80,0x88,0xdd,0x03,0x05,0x7f,0x00]
308 // VI-ERR: instruction not supported on this GPU
310 global_atomic_sub_x2 v[3:4], v[5:6], off
311 // GFX10: encoding: [0x00,0x80,0x4c,0xdd,0x03,0x05,0x7d,0x00]
312 // GFX9: global_atomic_sub_x2 v[3:4], v[5:6], off ; encoding: [0x00,0x80,0x8c,0xdd,0x03,0x05,0x7f,0x00]
313 // VI-ERR: instruction not supported on this GPU
315 global_atomic_smin_x2 v[3:4], v[5:6], off
316 // GFX10: encoding: [0x00,0x80,0x54,0xdd,0x03,0x05,0x7d,0x00]
317 // GFX9: global_atomic_smin_x2 v[3:4], v[5:6], off ; encoding: [0x00,0x80,0x90,0xdd,0x03,0x05,0x7f,0x00]
318 // VI-ERR: instruction not supported on this GPU
320 global_atomic_umin_x2 v[3:4], v[5:6], off
321 // GFX10: encoding: [0x00,0x80,0x58,0xdd,0x03,0x05,0x7d,0x00]
322 // GFX9: global_atomic_umin_x2 v[3:4], v[5:6], off ; encoding: [0x00,0x80,0x94,0xdd,0x03,0x05,0x7f,0x00]
323 // VI-ERR: instruction not supported on this GPU
325 global_atomic_smax_x2 v[3:4], v[5:6], off
326 // GFX10: encoding: [0x00,0x80,0x5c,0xdd,0x03,0x05,0x7d,0x00]
327 // GFX9: global_atomic_smax_x2 v[3:4], v[5:6], off ; encoding: [0x00,0x80,0x98,0xdd,0x03,0x05,0x7f,0x00]
328 // VI-ERR: instruction not supported on this GPU
330 global_atomic_umax_x2 v[3:4], v[5:6], off
331 // GFX10: encoding: [0x00,0x80,0x60,0xdd,0x03,0x05,0x7d,0x00]
332 // GFX9: global_atomic_umax_x2 v[3:4], v[5:6], off ; encoding: [0x00,0x80,0x9c,0xdd,0x03,0x05,0x7f,0x00]
333 // VI-ERR: instruction not supported on this GPU
335 global_atomic_and_x2 v[3:4], v[5:6], off
336 // GFX10: encoding: [0x00,0x80,0x64,0xdd,0x03,0x05,0x7d,0x00]
337 // GFX9: global_atomic_and_x2 v[3:4], v[5:6], off ; encoding: [0x00,0x80,0xa0,0xdd,0x03,0x05,0x7f,0x00]
338 // VI-ERR: instruction not supported on this GPU
340 global_atomic_or_x2 v[3:4], v[5:6], off
341 // GFX10: encoding: [0x00,0x80,0x68,0xdd,0x03,0x05,0x7d,0x00]
342 // GFX9: global_atomic_or_x2 v[3:4], v[5:6], off ; encoding: [0x00,0x80,0xa4,0xdd,0x03,0x05,0x7f,0x00]
343 // VI-ERR: instruction not supported on this GPU
345 global_atomic_xor_x2 v[3:4], v[5:6], off
346 // GFX10: encoding: [0x00,0x80,0x6c,0xdd,0x03,0x05,0x7d,0x00]
347 // GFX9: global_atomic_xor_x2 v[3:4], v[5:6], off ; encoding: [0x00,0x80,0xa8,0xdd,0x03,0x05,0x7f,0x00]
348 // VI-ERR: instruction not supported on this GPU
350 global_atomic_inc_x2 v[3:4], v[5:6], off
351 // GFX10: encoding: [0x00,0x80,0x70,0xdd,0x03,0x05,0x7d,0x00]
352 // GFX9: global_atomic_inc_x2 v[3:4], v[5:6], off ; encoding: [0x00,0x80,0xac,0xdd,0x03,0x05,0x7f,0x00]
353 // VI-ERR: instruction not supported on this GPU
355 global_atomic_dec_x2 v[3:4], v[5:6], off
356 // GFX10: encoding: [0x00,0x80,0x74,0xdd,0x03,0x05,0x7d,0x00]
357 // GFX9: global_atomic_dec_x2 v[3:4], v[5:6], off ; encoding: [0x00,0x80,0xb0,0xdd,0x03,0x05,0x7f,0x00]
358 // VI-ERR: error: instruction not supported on this GPU
360 global_atomic_cmpswap v[3:4], v[5:6], off offset:-16
361 // GFX10: encoding: [0xf0,0x8f,0xc4,0xdc,0x03,0x05,0x7d,0x00]
362 // GFX9: global_atomic_cmpswap v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0x04,0xdd,0x03,0x05,0x7f,0x00]
363 // VI-ERR: :43: error: not a valid operand.
365 global_atomic_cmpswap_x2 v[3:4], v[5:8], off offset:-16
366 // GFX10: encoding: [0xf0,0x8f,0x44,0xdd,0x03,0x05,0x7d,0x00]
367 // GFX9: global_atomic_cmpswap_x2 v[3:4], v[5:8], off offset:-16 ; encoding: [0xf0,0x9f,0x84,0xdd,0x03,0x05,0x7f,0x00]
368 // VI-ERR: :46: error: not a valid operand.
370 global_atomic_swap v[3:4], v5, off offset:-16
371 // GFX10: encoding: [0xf0,0x8f,0xc0,0xdc,0x03,0x05,0x7d,0x00]
372 // GFX9: global_atomic_swap v[3:4], v5, off offset:-16 ; encoding: [0xf0,0x9f,0x00,0xdd,0x03,0x05,0x7f,0x00]
373 // VI-ERR: :36: error: not a valid operand
375 global_atomic_swap_x2 v[3:4], v[5:6], off offset:-16
376 // GFX10: encoding: [0xf0,0x8f,0x40,0xdd,0x03,0x05,0x7d,0x00]
377 // GFX9: global_atomic_swap_x2 v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0x80,0xdd,0x03,0x05,0x7f,0x00]
378 // VI-ERR: :43: error: not a valid operand
380 global_atomic_add v[3:4], v5, off offset:-16
381 // GFX10: encoding: [0xf0,0x8f,0xc8,0xdc,0x03,0x05,0x7d,0x00]
382 // GFX9: global_atomic_add v[3:4], v5, off offset:-16 ; encoding: [0xf0,0x9f,0x08,0xdd,0x03,0x05,0x7f,0x00]
383 // VI-ERR: :35: error: not a valid operand
385 global_atomic_sub v[3:4], v5, off offset:-16
386 // GFX10: encoding: [0xf0,0x8f,0xcc,0xdc,0x03,0x05,0x7d,0x00]
387 // GFX9: global_atomic_sub v[3:4], v5, off offset:-16 ; encoding: [0xf0,0x9f,0x0c,0xdd,0x03,0x05,0x7f,0x00]
388 // VI-ERR: :35: error: not a valid operand
390 global_atomic_smin v[3:4], v5, off offset:-16
391 // GFX10: encoding: [0xf0,0x8f,0xd4,0xdc,0x03,0x05,0x7d,0x00]
392 // GFX9: global_atomic_smin v[3:4], v5, off offset:-16 ; encoding: [0xf0,0x9f,0x10,0xdd,0x03,0x05,0x7f,0x00]
393 // VI-ERR: :36: error: not a valid operand
395 global_atomic_umin v[3:4], v5, off offset:-16
396 // GFX10: encoding: [0xf0,0x8f,0xd8,0xdc,0x03,0x05,0x7d,0x00]
397 // GFX9: global_atomic_umin v[3:4], v5, off offset:-16 ; encoding: [0xf0,0x9f,0x14,0xdd,0x03,0x05,0x7f,0x00]
398 // VI-ERR: :36: error: not a valid operand
400 global_atomic_smax v[3:4], v5, off offset:-16
401 // GFX10: encoding: [0xf0,0x8f,0xdc,0xdc,0x03,0x05,0x7d,0x00]
402 // GFX9: global_atomic_smax v[3:4], v5, off offset:-16 ; encoding: [0xf0,0x9f,0x18,0xdd,0x03,0x05,0x7f,0x00]
403 // VI-ERR: :36: error: not a valid operand
405 global_atomic_umax v[3:4], v5, off offset:-16
406 // GFX10: encoding: [0xf0,0x8f,0xe0,0xdc,0x03,0x05,0x7d,0x00]
407 // GFX9: global_atomic_umax v[3:4], v5, off offset:-16 ; encoding: [0xf0,0x9f,0x1c,0xdd,0x03,0x05,0x7f,0x00]
408 // VI-ERR: :36: error: not a valid operand
410 global_atomic_and v[3:4], v5, off offset:-16
411 // GFX10: encoding: [0xf0,0x8f,0xe4,0xdc,0x03,0x05,0x7d,0x00]
412 // GFX9: global_atomic_and v[3:4], v5, off offset:-16 ; encoding: [0xf0,0x9f,0x20,0xdd,0x03,0x05,0x7f,0x00]
413 // VI-ERR: :35: error: not a valid operand
415 global_atomic_or v[3:4], v5, off offset:-16
416 // GFX10: encoding: [0xf0,0x8f,0xe8,0xdc,0x03,0x05,0x7d,0x00]
417 // GFX9: global_atomic_or v[3:4], v5, off offset:-16 ; encoding: [0xf0,0x9f,0x24,0xdd,0x03,0x05,0x7f,0x00]
418 // VI-ERR: :34: error: not a valid operand
420 global_atomic_xor v[3:4], v5, off offset:-16
421 // GFX10: encoding: [0xf0,0x8f,0xec,0xdc,0x03,0x05,0x7d,0x00]
422 // GFX9: global_atomic_xor v[3:4], v5, off offset:-16 ; encoding: [0xf0,0x9f,0x28,0xdd,0x03,0x05,0x7f,0x00]
423 // VI-ERR: :35: error: not a valid operand
425 global_atomic_inc v[3:4], v5, off offset:-16
426 // GFX10: encoding: [0xf0,0x8f,0xf0,0xdc,0x03,0x05,0x7d,0x00]
427 // GFX9: global_atomic_inc v[3:4], v5, off offset:-16 ; encoding: [0xf0,0x9f,0x2c,0xdd,0x03,0x05,0x7f,0x00]
428 // VI-ERR: :35: error: not a valid operand
430 global_atomic_dec v[3:4], v5, off offset:-16
431 // GFX10: encoding: [0xf0,0x8f,0xf4,0xdc,0x03,0x05,0x7d,0x00]
432 // GFX9: global_atomic_dec v[3:4], v5, off offset:-16 ; encoding: [0xf0,0x9f,0x30,0xdd,0x03,0x05,0x7f,0x00]
433 // VI-ERR: :35: error: not a valid operand
435 global_atomic_add_x2 v[3:4], v[5:6], off offset:-16
436 // GFX10: encoding: [0xf0,0x8f,0x48,0xdd,0x03,0x05,0x7d,0x00]
437 // GFX9: global_atomic_add_x2 v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0x88,0xdd,0x03,0x05,0x7f,0x00]
438 // VI-ERR: :42: error: not a valid operand
440 global_atomic_sub_x2 v[3:4], v[5:6], off offset:-16
441 // GFX10: encoding: [0xf0,0x8f,0x4c,0xdd,0x03,0x05,0x7d,0x00]
442 // GFX9: global_atomic_sub_x2 v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0x8c,0xdd,0x03,0x05,0x7f,0x00]
443 // VI-ERR: :42: error: not a valid operand
445 global_atomic_smin_x2 v[3:4], v[5:6], off offset:-16
446 // GFX10: encoding: [0xf0,0x8f,0x54,0xdd,0x03,0x05,0x7d,0x00]
447 // GFX9: global_atomic_smin_x2 v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0x90,0xdd,0x03,0x05,0x7f,0x00]
448 // VI-ERR: :43: error: not a valid operand
450 global_atomic_umin_x2 v[3:4], v[5:6], off offset:-16
451 // GFX10: encoding: [0xf0,0x8f,0x58,0xdd,0x03,0x05,0x7d,0x00]
452 // GFX9: global_atomic_umin_x2 v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0x94,0xdd,0x03,0x05,0x7f,0x00]
453 // VI-ERR: :43: error: not a valid operand
455 global_atomic_smax_x2 v[3:4], v[5:6], off offset:-16
456 // GFX10: encoding: [0xf0,0x8f,0x5c,0xdd,0x03,0x05,0x7d,0x00]
457 // GFX9: global_atomic_smax_x2 v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0x98,0xdd,0x03,0x05,0x7f,0x00]
458 // VI-ERR: :43: error: not a valid operand
460 global_atomic_umax_x2 v[3:4], v[5:6], off offset:-16
461 // GFX10: encoding: [0xf0,0x8f,0x60,0xdd,0x03,0x05,0x7d,0x00]
462 // GFX9: global_atomic_umax_x2 v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0x9c,0xdd,0x03,0x05,0x7f,0x00]
463 // VI-ERR: :43: error: not a valid operand
465 global_atomic_and_x2 v[3:4], v[5:6], off offset:-16
466 // GFX10: encoding: [0xf0,0x8f,0x64,0xdd,0x03,0x05,0x7d,0x00]
467 // GFX9: global_atomic_and_x2 v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0xa0,0xdd,0x03,0x05,0x7f,0x00]
468 // VI-ERR: :42: error: not a valid operand
470 global_atomic_or_x2 v[3:4], v[5:6], off offset:-16
471 // GFX10: encoding: [0xf0,0x8f,0x68,0xdd,0x03,0x05,0x7d,0x00]
472 // GFX9: global_atomic_or_x2 v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0xa4,0xdd,0x03,0x05,0x7f,0x00]
473 // VI-ERR: :41: error: not a valid operand
475 global_atomic_xor_x2 v[3:4], v[5:6], off offset:-16
476 // GFX10: encoding: [0xf0,0x8f,0x6c,0xdd,0x03,0x05,0x7d,0x00]
477 // GFX9: global_atomic_xor_x2 v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0xa8,0xdd,0x03,0x05,0x7f,0x00]
478 // VI-ERR: :42: error: not a valid operand
480 global_atomic_inc_x2 v[3:4], v[5:6], off offset:-16
481 // GFX10: encoding: [0xf0,0x8f,0x70,0xdd,0x03,0x05,0x7d,0x00]
482 // GFX9: global_atomic_inc_x2 v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0xac,0xdd,0x03,0x05,0x7f,0x00]
483 // VI-ERR: :42: error: not a valid operand
485 global_atomic_dec_x2 v[3:4], v[5:6], off offset:-16
486 // GFX10: encoding: [0xf0,0x8f,0x74,0xdd,0x03,0x05,0x7d,0x00]
487 // GFX9: global_atomic_dec_x2 v[3:4], v[5:6], off offset:-16 ; encoding: [0xf0,0x9f,0xb0,0xdd,0x03,0x05,0x7f,0x00]
488 // VI-ERR: :42: error: not a valid operand
490 global_load_ubyte_d16 v1, v[3:4], off
491 // GFX10: encoding: [0x00,0x80,0x80,0xdc,0x03,0x00,0x7d,0x01]
492 // GFX9: global_load_ubyte_d16 v1, v[3:4], off ; encoding: [0x00,0x80,0x80,0xdc,0x03,0x00,0x7f,0x01]
493 // VI-ERR: instruction not supported on this GPU
495 global_load_ubyte_d16_hi v1, v[3:4], off
496 // GFX10: encoding: [0x00,0x80,0x84,0xdc,0x03,0x00,0x7d,0x01]
497 // GFX9: global_load_ubyte_d16_hi v1, v[3:4], off ; encoding: [0x00,0x80,0x84,0xdc,0x03,0x00,0x7f,0x01]
498 // VI-ERR: instruction not supported on this GPU
500 global_load_sbyte_d16 v1, v[3:4], off
501 // GFX10: encoding: [0x00,0x80,0x88,0xdc,0x03,0x00,0x7d,0x01]
502 // GFX9: global_load_sbyte_d16 v1, v[3:4], off ; encoding: [0x00,0x80,0x88,0xdc,0x03,0x00,0x7f,0x01]
503 // VI-ERR: instruction not supported on this GPU
505 global_load_sbyte_d16_hi v1, v[3:4], off
506 // GFX10: encoding: [0x00,0x80,0x8c,0xdc,0x03,0x00,0x7d,0x01]
507 // GFX9: global_load_sbyte_d16_hi v1, v[3:4], off ; encoding: [0x00,0x80,0x8c,0xdc,0x03,0x00,0x7f,0x01]
508 // VI-ERR: instruction not supported on this GPU
510 global_load_short_d16 v1, v[3:4], off
511 // GFX10: encoding: [0x00,0x80,0x90,0xdc,0x03,0x00,0x7d,0x01]
512 // GFX9: global_load_short_d16 v1, v[3:4], off ; encoding: [0x00,0x80,0x90,0xdc,0x03,0x00,0x7f,0x01]
513 // VI-ERR: instruction not supported on this GPU
515 global_load_short_d16_hi v1, v[3:4], off
516 // GFX10: encoding: [0x00,0x80,0x94,0xdc,0x03,0x00,0x7d,0x01]
517 // GFX9: global_load_short_d16_hi v1, v[3:4], off ; encoding: [0x00,0x80,0x94,0xdc,0x03,0x00,0x7f,0x01]
518 // VI-ERR: instruction not supported on this GPU
520 global_store_byte_d16_hi v[3:4], v1, off
521 // GFX10: encoding: [0x00,0x80,0x64,0xdc,0x03,0x01,0x7d,0x00]
522 // GFX9: global_store_byte_d16_hi v[3:4], v1, off ; encoding: [0x00,0x80,0x64,0xdc,0x03,0x01,0x7f,0x00]
523 // VI-ERR: instruction not supported on this GPU
525 global_store_short_d16_hi v[3:4], v1, off
526 // GFX10: encoding: [0x00,0x80,0x6c,0xdc,0x03,0x01,0x7d,0x00]
527 // GFX9: global_store_short_d16_hi v[3:4], v1, off ; encoding: [0x00,0x80,0x6c,0xdc,0x03,0x01,0x7f,0x00]
528 // VI-ERR: instruction not supported on this GPU