• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// RUN: not llvm-mc -arch=amdgcn -mcpu=gfx900 %s 2>&1 | FileCheck -check-prefix=GFX9 --implicit-check-not=error: %s
2
3// GFX9: 25: error: invalid operand for instruction
4v_pk_add_u16 v1, v2, v3 op_sel
5
6// GFX9: 32: error: expected a left square bracket
7v_pk_add_u16 v1, v2, v3 op_sel:
8
9// GFX9: 33: error: unknown token in expression
10v_pk_add_u16 v1, v2, v3 op_sel:[
11
12// GFX9: 33: error: unknown token in expression
13v_pk_add_u16 v1, v2, v3 op_sel:[]
14
15// GFX9: 33: error: unknown token in expression
16v_pk_add_u16 v1, v2, v3 op_sel:[,]
17
18// FIXME: Should trigger an error.
19// v_pk_add_u16 v1, v2, v3 op_sel:[0]
20
21// GFX9: 35: error: expected a comma
22v_pk_add_u16 v1, v2, v3 op_sel:[0 0]
23
24// GFX9: 35: error: unknown token in expression
25v_pk_add_u16 v1, v2, v3 op_sel:[0,]
26
27// GFX9: 33: error: unknown token in expression
28v_pk_add_u16 v1, v2, v3 op_sel:[,0]
29
30// GFX9: 42: error: expected a closing square bracket
31v_max3_f16 v5, v1, v2, v3 op_sel:[1,1,1,1,
32
33// GFX9: 42: error: expected a closing square bracket
34v_max3_f16 v5, v1, v2, v3 op_sel:[1,1,1,1[
35
36// GFX9: 43: error: expected a closing square bracket
37v_max3_f16 v5, v1, v2, v3 op_sel:[1,1,1,1 1
38
39// GFX9: 35: error: invalid op_sel value.
40v_pk_add_u16 v1, v2, v3 op_sel:[0,2]
41
42// GFX9: 33: error: invalid op_sel value.
43v_pk_add_u16 v1, v2, v3 op_sel:[2,0]
44
45// GFX9: 33: error: invalid op_sel value.
46v_pk_add_u16 v1, v2, v3 op_sel:[-1,0]
47
48// GFX9: 35: error: invalid op_sel value.
49v_pk_add_u16 v1, v2, v3 op_sel:[0,-1]
50
51// GFX9: 40: error: expected a closing square bracket
52v_pk_add_u16 v1, v2, v3 op_sel:[0,0,0,0,0]
53
54// FIXME: should trigger an error
55v_pk_add_u16 v1, v2, v3 neg_lo:[0,0]
56
57//
58// Regular modifiers on packed instructions
59//
60
61// FIXME: should be "invalid operand for instruction"
62// GFX9: :18: error: not a valid operand.
63v_pk_add_f16 v1, |v2|, v3
64
65// GFX9: :18: error: not a valid operand
66v_pk_add_f16 v1, abs(v2), v3
67
68// GFX9: :22: error: not a valid operand.
69v_pk_add_f16 v1, v2, |v3|
70
71// GFX9: :22: error: not a valid operand.
72v_pk_add_f16 v1, v2, abs(v3)
73
74// GFX9: :18: error: not a valid operand.
75v_pk_add_f16 v1, -v2, v3
76
77// GFX9: :22: error: not a valid operand.
78v_pk_add_f16 v1, v2, -v3
79
80// GFX9: :18: error: not a valid operand.
81v_pk_add_u16 v1, abs(v2), v3
82
83// GFX9: :18: error: not a valid operand.
84v_pk_add_u16 v1, -v2, v3
85
86//
87// Constant bus restrictions
88//
89
90// GFX9: error: invalid operand (violates constant bus restrictions)
91v_pk_add_f16 v255, s1, s2
92