xref: /llvm-project/llvm/test/MC/RISCV/corev/XCValu-invalid.s (revision 092e60a3fcb642e0a1d08c4c30722995573c7d4d)
1# RUN: not llvm-mc -triple=riscv32 --mattr=+xcvalu %s 2>&1 \
2# RUN:        | FileCheck %s --check-prefixes=CHECK-ERROR
3
4cv.addrnr t0, t1, 0
5# CHECK-ERROR: invalid operand for instruction
6
7cv.addrnr t0, 0, t2
8# CHECK-ERROR: invalid operand for instruction
9
10cv.addrnr 0, t1, t2
11# CHECK-ERROR: invalid operand for instruction
12
13cv.addrnr t0, t1
14# CHECK-ERROR: too few operands for instruction
15
16cv.addrnr t0, t1, t2, a0
17# CHECK-ERROR: invalid operand for instruction
18
19cv.addun t0, t1, t2, -1
20# CHECK-ERROR: immediate must be an integer in the range [0, 31]
21
22cv.addun t0, t1, t2, 32
23# CHECK-ERROR: immediate must be an integer in the range [0, 31]
24
25cv.addun t0, t1, t2, a0
26# CHECK-ERROR: immediate must be an integer in the range [0, 31]
27
28cv.addun t0, t1, 0, 0
29# CHECK-ERROR: invalid operand for instruction
30
31cv.addun t0, 0, t2, 0
32# CHECK-ERROR: invalid operand for instruction
33
34cv.addun 0, t1, t2, 0
35# CHECK-ERROR: invalid operand for instruction
36
37cv.addun t0, t1, t2
38# CHECK-ERROR: too few operands for instruction
39
40cv.addun t0, t1, t2, 0, a0
41# CHECK-ERROR: invalid operand for instruction
42
43cv.extbz t0, 0
44# CHECK-ERROR: invalid operand for instruction
45
46cv.extbz 0, t1
47# CHECK-ERROR: invalid operand for instruction
48
49cv.extbz t0
50# CHECK-ERROR: too few operands for instruction
51
52cv.extbz t0, t1, t2
53# CHECK-ERROR: invalid operand for instruction
54
55cv.addnr t0, t1, 0
56# CHECK-ERROR: invalid operand for instruction
57
58cv.addnr t0, 0, t2
59# CHECK-ERROR: invalid operand for instruction
60
61cv.addnr 0, t1, t2
62# CHECK-ERROR: invalid operand for instruction
63
64cv.addnr t0, t1
65# CHECK-ERROR: too few operands for instruction
66
67cv.addnr t0, t1, t2, a0
68# CHECK-ERROR: invalid operand for instruction
69
70cv.clipu t0, t1, -1
71# CHECK-ERROR: immediate must be an integer in the range [0, 31]
72
73cv.clipu t0, t1, 32
74# CHECK-ERROR: immediate must be an integer in the range [0, 31]
75
76cv.clipu t0, t1, a0
77# CHECK-ERROR: immediate must be an integer in the range [0, 31]
78
79cv.clipu t0, 0, 0
80# CHECK-ERROR: invalid operand for instruction
81
82cv.clipu 0, t1, 0
83# CHECK-ERROR: invalid operand for instruction
84
85cv.clipu t0, t1
86# CHECK-ERROR: too few operands for instruction
87
88cv.clipu t0, t1, 0, 0
89# CHECK-ERROR: invalid operand for instruction
90
91cv.minu t0, t1, 0
92# CHECK-ERROR: invalid operand for instruction
93
94cv.minu t0, 0, t2
95# CHECK-ERROR: invalid operand for instruction
96
97cv.minu 0, t1, t2
98# CHECK-ERROR: invalid operand for instruction
99
100cv.minu t0, t1
101# CHECK-ERROR: too few operands for instruction
102
103cv.minu t0, t1, t2, a0
104# CHECK-ERROR: invalid operand for instruction
105
106cv.abs t0, 0
107# CHECK-ERROR: invalid operand for instruction
108
109cv.abs 0, t1
110# CHECK-ERROR: invalid operand for instruction
111
112cv.abs t0
113# CHECK-ERROR: too few operands for instruction
114
115cv.abs t0, t1, t2
116# CHECK-ERROR: invalid operand for instruction
117
118cv.addrn t0, t1, t2, -1
119# CHECK-ERROR: immediate must be an integer in the range [0, 31]
120
121cv.addrn t0, t1, t2, 32
122# CHECK-ERROR: immediate must be an integer in the range [0, 31]
123
124cv.addrn t0, t1, t2, a0
125# CHECK-ERROR: immediate must be an integer in the range [0, 31]
126
127cv.addrn t0, t1, 0, 0
128# CHECK-ERROR: invalid operand for instruction
129
130cv.addrn t0, 0, t2, 0
131# CHECK-ERROR: invalid operand for instruction
132
133cv.addrn 0, t1, t2, 0
134# CHECK-ERROR: invalid operand for instruction
135
136cv.addrn t0, t1, t2
137# CHECK-ERROR: too few operands for instruction
138
139cv.addrn t0, t1, t2, 0, a0
140# CHECK-ERROR: invalid operand for instruction
141
142cv.suburn t0, t1, t2, -1
143# CHECK-ERROR: immediate must be an integer in the range [0, 31]
144
145cv.suburn t0, t1, t2, 32
146# CHECK-ERROR: immediate must be an integer in the range [0, 31]
147
148cv.suburn t0, t1, t2, a0
149# CHECK-ERROR: immediate must be an integer in the range [0, 31]
150
151cv.suburn t0, t1, 0, 0
152# CHECK-ERROR: invalid operand for instruction
153
154cv.suburn t0, 0, t2, 0
155# CHECK-ERROR: invalid operand for instruction
156
157cv.suburn 0, t1, t2, 0
158# CHECK-ERROR: invalid operand for instruction
159
160cv.suburn t0, t1, t2
161# CHECK-ERROR: too few operands for instruction
162
163cv.suburn t0, t1, t2, 0, a0
164# CHECK-ERROR: invalid operand for instruction
165
166cv.clip t0, t1, -1
167# CHECK-ERROR: immediate must be an integer in the range [0, 31]
168
169cv.clip t0, t1, 32
170# CHECK-ERROR: immediate must be an integer in the range [0, 31]
171
172cv.clip t0, t1, a0
173# CHECK-ERROR: immediate must be an integer in the range [0, 31]
174
175cv.clip t0, 0, 0
176# CHECK-ERROR: invalid operand for instruction
177
178cv.clip 0, t1, 0
179# CHECK-ERROR: invalid operand for instruction
180
181cv.clip t0, t1
182# CHECK-ERROR: too few operands for instruction
183
184cv.clip t0, t1, 0, 0
185# CHECK-ERROR: invalid operand for instruction
186
187cv.addunr t0, t1, 0
188# CHECK-ERROR: invalid operand for instruction
189
190cv.addunr t0, 0, t2
191# CHECK-ERROR: invalid operand for instruction
192
193cv.addunr 0, t1, t2
194# CHECK-ERROR: invalid operand for instruction
195
196cv.addunr t0, t1
197# CHECK-ERROR: too few operands for instruction
198
199cv.addunr t0, t1, t2, a0
200# CHECK-ERROR: invalid operand for instruction
201
202cv.addurn t0, t1, t2, -1
203# CHECK-ERROR: immediate must be an integer in the range [0, 31]
204
205cv.addurn t0, t1, t2, 32
206# CHECK-ERROR: immediate must be an integer in the range [0, 31]
207
208cv.addurn t0, t1, t2, a0
209# CHECK-ERROR: immediate must be an integer in the range [0, 31]
210
211cv.addurn t0, t1, 0, 0
212# CHECK-ERROR: invalid operand for instruction
213
214cv.addurn t0, 0, t2, 0
215# CHECK-ERROR: invalid operand for instruction
216
217cv.addurn 0, t1, t2, 0
218# CHECK-ERROR: invalid operand for instruction
219
220cv.addurn t0, t1, t2
221# CHECK-ERROR: too few operands for instruction
222
223cv.addurn t0, t1, t2, 0, a0
224# CHECK-ERROR: invalid operand for instruction
225
226cv.subun t0, t1, t2, -1
227# CHECK-ERROR: immediate must be an integer in the range [0, 31]
228
229cv.subun t0, t1, t2, 32
230# CHECK-ERROR: immediate must be an integer in the range [0, 31]
231
232cv.subun t0, t1, t2, a0
233# CHECK-ERROR: immediate must be an integer in the range [0, 31]
234
235cv.subun t0, t1, 0, 0
236# CHECK-ERROR: invalid operand for instruction
237
238cv.subun t0, 0, t2, 0
239# CHECK-ERROR: invalid operand for instruction
240
241cv.subun 0, t1, t2, 0
242# CHECK-ERROR: invalid operand for instruction
243
244cv.subun t0, t1, t2
245# CHECK-ERROR: too few operands for instruction
246
247cv.subun t0, t1, t2, 0, a0
248# CHECK-ERROR: invalid operand for instruction
249
250cv.subn t0, t1, t2, -1
251# CHECK-ERROR: immediate must be an integer in the range [0, 31]
252
253cv.subn t0, t1, t2, 32
254# CHECK-ERROR: immediate must be an integer in the range [0, 31]
255
256cv.subn t0, t1, t2, a0
257# CHECK-ERROR: immediate must be an integer in the range [0, 31]
258
259cv.subn t0, t1, 0, 0
260# CHECK-ERROR: invalid operand for instruction
261
262cv.subn t0, 0, t2, 0
263# CHECK-ERROR: invalid operand for instruction
264
265cv.subn 0, t1, t2, 0
266# CHECK-ERROR: invalid operand for instruction
267
268cv.subn t0, t1, t2
269# CHECK-ERROR: too few operands for instruction
270
271cv.subn t0, t1, t2, 0, a0
272# CHECK-ERROR: invalid operand for instruction
273
274cv.subrnr t0, t1, 0
275# CHECK-ERROR: invalid operand for instruction
276
277cv.subrnr t0, 0, t2
278# CHECK-ERROR: invalid operand for instruction
279
280cv.subrnr 0, t1, t2
281# CHECK-ERROR: invalid operand for instruction
282
283cv.subrnr t0, t1
284# CHECK-ERROR: too few operands for instruction
285
286cv.subrnr t0, t1, t2, a0
287# CHECK-ERROR: invalid operand for instruction
288
289cv.slet t0, t1, 0
290# CHECK-ERROR: invalid operand for instruction
291
292cv.slet t0, 0, t2
293# CHECK-ERROR: invalid operand for instruction
294
295cv.slet 0, t1, t2
296# CHECK-ERROR: invalid operand for instruction
297
298cv.slet t0, t1
299# CHECK-ERROR: too few operands for instruction
300
301cv.slet t0, t1, t2, a0
302# CHECK-ERROR: invalid operand for instruction
303
304cv.suburnr t0, t1, 0
305# CHECK-ERROR: invalid operand for instruction
306
307cv.suburnr t0, 0, t2
308# CHECK-ERROR: invalid operand for instruction
309
310cv.suburnr 0, t1, t2
311# CHECK-ERROR: invalid operand for instruction
312
313cv.suburnr t0, t1
314# CHECK-ERROR: too few operands for instruction
315
316cv.suburnr t0, t1, t2, a0
317# CHECK-ERROR: invalid operand for instruction
318
319cv.maxu t0, t1, 0
320# CHECK-ERROR: invalid operand for instruction
321
322cv.maxu t0, 0, t2
323# CHECK-ERROR: invalid operand for instruction
324
325cv.maxu 0, t1, t2
326# CHECK-ERROR: invalid operand for instruction
327
328cv.maxu t0, t1
329# CHECK-ERROR: too few operands for instruction
330
331cv.maxu t0, t1, t2, a0
332# CHECK-ERROR: invalid operand for instruction
333
334cv.extbs t0, 0
335# CHECK-ERROR: invalid operand for instruction
336
337cv.extbs 0, t1
338# CHECK-ERROR: invalid operand for instruction
339
340cv.extbs t0
341# CHECK-ERROR: too few operands for instruction
342
343cv.extbs t0, t1, t2
344# CHECK-ERROR: invalid operand for instruction
345
346cv.exths t0, 0
347# CHECK-ERROR: invalid operand for instruction
348
349cv.exths 0, t1
350# CHECK-ERROR: invalid operand for instruction
351
352cv.exths t0
353# CHECK-ERROR: too few operands for instruction
354
355cv.exths t0, t1, t2
356# CHECK-ERROR: invalid operand for instruction
357
358cv.max t0, t1, 0
359# CHECK-ERROR: invalid operand for instruction
360
361cv.max t0, 0, t2
362# CHECK-ERROR: invalid operand for instruction
363
364cv.max 0, t1, t2
365# CHECK-ERROR: invalid operand for instruction
366
367cv.max t0, t1
368# CHECK-ERROR: too few operands for instruction
369
370cv.max t0, t1, t2, a0
371# CHECK-ERROR: invalid operand for instruction
372
373cv.subunr t0, t1, 0
374# CHECK-ERROR: invalid operand for instruction
375
376cv.subunr t0, 0, t2
377# CHECK-ERROR: invalid operand for instruction
378
379cv.subunr 0, t1, t2
380# CHECK-ERROR: invalid operand for instruction
381
382cv.subunr t0, t1
383# CHECK-ERROR: too few operands for instruction
384
385cv.subunr t0, t1, t2, a0
386# CHECK-ERROR: invalid operand for instruction
387
388cv.exthz t0, 0
389# CHECK-ERROR: invalid operand for instruction
390
391cv.exthz 0, t1
392# CHECK-ERROR: invalid operand for instruction
393
394cv.exthz t0
395# CHECK-ERROR: too few operands for instruction
396
397cv.exthz t0, t1, t2
398# CHECK-ERROR: invalid operand for instruction
399
400cv.clipur t0, t1, 0
401# CHECK-ERROR: invalid operand for instruction
402
403cv.clipur t0, 0, t2
404# CHECK-ERROR: invalid operand for instruction
405
406cv.clipur 0, t1, t2
407# CHECK-ERROR: invalid operand for instruction
408
409cv.clipur t0, t1
410# CHECK-ERROR: too few operands for instruction
411
412cv.clipur t0, t1, t2, a0
413# CHECK-ERROR: invalid operand for instruction
414
415cv.addurnr t0, t1, 0
416# CHECK-ERROR: invalid operand for instruction
417
418cv.addurnr t0, 0, t2
419# CHECK-ERROR: invalid operand for instruction
420
421cv.addurnr 0, t1, t2
422# CHECK-ERROR: invalid operand for instruction
423
424cv.addurnr t0, t1
425# CHECK-ERROR: too few operands for instruction
426
427cv.addurnr t0, t1, t2, a0
428# CHECK-ERROR: invalid operand for instruction
429
430cv.addn t0, t1, t2, -1
431# CHECK-ERROR: immediate must be an integer in the range [0, 31]
432
433cv.addn t0, t1, t2, 32
434# CHECK-ERROR: immediate must be an integer in the range [0, 31]
435
436cv.addn t0, t1, t2, a0
437# CHECK-ERROR: immediate must be an integer in the range [0, 31]
438
439cv.addn t0, t1, 0, 0
440# CHECK-ERROR: invalid operand for instruction
441
442cv.addn t0, 0, t2, 0
443# CHECK-ERROR: invalid operand for instruction
444
445cv.addn 0, t1, t2, 0
446# CHECK-ERROR: invalid operand for instruction
447
448cv.addn t0, t1, t2
449# CHECK-ERROR: too few operands for instruction
450
451cv.addn t0, t1, t2, 0, a0
452# CHECK-ERROR: invalid operand for instruction
453
454cv.subrn t0, t1, t2, -1
455# CHECK-ERROR: immediate must be an integer in the range [0, 31]
456
457cv.subrn t0, t1, t2, 32
458# CHECK-ERROR: immediate must be an integer in the range [0, 31]
459
460cv.subrn t0, t1, t2, a0
461# CHECK-ERROR: immediate must be an integer in the range [0, 31]
462
463cv.subrn t0, t1, 0, 0
464# CHECK-ERROR: invalid operand for instruction
465
466cv.subrn t0, 0, t2, 0
467# CHECK-ERROR: invalid operand for instruction
468
469cv.subrn 0, t1, t2, 0
470# CHECK-ERROR: invalid operand for instruction
471
472cv.subrn t0, t1, t2
473# CHECK-ERROR: too few operands for instruction
474
475cv.subrn t0, t1, t2, 0, a0
476# CHECK-ERROR: invalid operand for instruction
477
478cv.subnr t0, t1, 0
479# CHECK-ERROR: invalid operand for instruction
480
481cv.subnr t0, 0, t2
482# CHECK-ERROR: invalid operand for instruction
483
484cv.subnr 0, t1, t2
485# CHECK-ERROR: invalid operand for instruction
486
487cv.subnr t0, t1
488# CHECK-ERROR: too few operands for instruction
489
490cv.subnr t0, t1, t2, a0
491# CHECK-ERROR: invalid operand for instruction
492
493cv.clipr t0, t1, 0
494# CHECK-ERROR: invalid operand for instruction
495
496cv.clipr t0, 0, t2
497# CHECK-ERROR: invalid operand for instruction
498
499cv.clipr 0, t1, t2
500# CHECK-ERROR: invalid operand for instruction
501
502cv.clipr t0, t1
503# CHECK-ERROR: too few operands for instruction
504
505cv.clipr t0, t1, t2, a0
506# CHECK-ERROR: invalid operand for instruction
507
508cv.sletu t0, t1, 0
509# CHECK-ERROR: invalid operand for instruction
510
511cv.sletu t0, 0, t2
512# CHECK-ERROR: invalid operand for instruction
513
514cv.sletu 0, t1, t2
515# CHECK-ERROR: invalid operand for instruction
516
517cv.sletu t0, t1
518# CHECK-ERROR: too few operands for instruction
519
520cv.sletu t0, t1, t2, a0
521# CHECK-ERROR: invalid operand for instruction
522
523cv.min t0, t1, 0
524# CHECK-ERROR: invalid operand for instruction
525
526cv.min t0, 0, t2
527# CHECK-ERROR: invalid operand for instruction
528
529cv.min 0, t1, t2
530# CHECK-ERROR: invalid operand for instruction
531
532cv.min t0, t1
533# CHECK-ERROR: too few operands for instruction
534
535cv.min t0, t1, t2, a0
536# CHECK-ERROR: invalid operand for instruction
537