[obj2yaml] - Fix a comment. NFC.
[llvm-complete.git] / test / MC / ARM / directive_parsing.s
blob996473bbd45b9ee27c603d8471379caef7c5fc47
1 // RUN: not llvm-mc -triple armv7--none-eabi %s 2>&1 | FileCheck %s
2 // RUN: not llvm-mc -triple armv7--none-eabi %s 2>&1 | grep "error:" | count 33
4 // CHECK: [[@LINE+1]]:10: error: unexpected token
5 .word 0 $
6 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
7 .word 0 @ EOL COMMENT
8 // CHECK: [[@LINE+1]]:11: error: unexpected token
9 .short 0 $
10 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
11 .short 0 @ EOL COMMENT
12 // CHECK: [[@LINE+1]]:11: error: unexpected token
13 .hword 0 $
14 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
15 .hword 0 @ EOL COMMENT
17 .arch armv7-a
18 // CHECK: [[@LINE+1]]:9: error: unexpected token in directive
19 .thumb $
20 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
21 .thumb @ EOL COMMENT
23 // CHECK: [[@LINE+1]]:7: error: unexpected token in directive
24 .arm $
25 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
26 .arm @ EOL COMMENT
27 // CHECK: [[@LINE+1]]:14: error: unexpected token in '.thumb_func' directive
28 .thumb_func $
29 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
30 .thumb_func @ EOL COMMENT
31 // CHECK: [[@LINE+1]]:11: error: unexpected token in directive
32 .code 16 $
33 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
34 .code 16 @ EOL COMMENTS
35 // CHECK: [[@LINE+1]]:18: error: unexpected token in directive
36 .syntax unified $
37 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
38 .syntax unified @ EOL COMMENT
39 fred .req r5
40 // CHECK: [[@LINE+1]]:14: error: unexpected input in '.unreq' directive
41 .unreq fred $
42 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
43 .unreq fred @ EOL COMMENTS
45 // CHECK: [[@LINE+1]]:18: error: unexpected token in '.fnstart' directive
46 .fnstart $
47 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
48 .fnstart @ EOL COMMENT
49 // CHECK: [[@LINE+1]]:23: error: unexpected token in '.cantunwind' directive
50 .cantunwind $
51 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
52 .cantunwind @ EOL COMMENT
55 // CHECK: [[@LINE+1]]:18: error: unexpected token in '.fnend' directive
56 .fnend $
57 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
58 .fnend @ EOL COMMENT
60 .fnstart
61 // CHECK: [[@LINE+1]]:43: error: unexpected token in '.personality' directive
62 .personality __gxx_personality_v0 $
63 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
64 .personality __gxx_personality_v0 @ EOL COMMENET
66 // CHECK: [[@LINE+1]]:28: error: unexpected token
67 .setfp fp, sp, #0 $
68 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
69 .setfp fp, sp, #0 @ EOL COMMENT
72 // CHECK: [[@LINE+1]]:17: error: unexpected token in '.pad' directive
73 .pad #0 $
74 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
75 .pad #0 @ EOL COMMENT
77 // CHECK: [[@LINE+1]]:20: error: unexpected token in directive
78 .save {r0} $
79 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
80 .save {r0} @ EOL COMMENT
82 // CHECK: [[@LINE+1]]:21: error: unexpected token in directive
83 .vsave {d0} $
84 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
85 .vsave {d0} @ EOL COMMENT
88 // CHECK: [[@LINE+1]]:22: error: unexpected token in '.handlerdata' directive
89 .handlerdata $
90 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
91 .handlerdata @ EOL COMMENT
93 .fnend
95 // CHECK: [[@LINE+1]]:9: error: unexpected token in directive
96 .ltorg $
97 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
98 .ltorg @ EOL COMMENT
99 // CHECK: [[@LINE+1]]:8: error: unexpected token in directive
100 .pool $
101 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
102 .pool @ EOL COMMENT
103 // CHECK: [[@LINE+1]]:8: error: unexpected token in directive
104 .even $
105 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
106 .even @ EOL COMMENT
107 .fnstart
108 // CHECK: [[@LINE+1]]:22: error: unexpected token in '.personalityindex' directive
109 .personalityindex 0 $
110 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
111 .personalityindex 0 @ EOL COMMENT
112 .fnend
114 .fnstart
115 // CHECK: [[@LINE+1]]:19: error: unexpected token
116 .unwind_raw 0, 0 $
117 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
118 .unwind_raw 0, 0 @ EOL COMMENT
120 // CHECK: [[@LINE+1]]:12: error: unexpected token in '.movsp' directive
121 .movsp r0 $
122 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
123 .movsp r1 @ EOL COMMENT
124 .fnend
126 // CHECK: [[@LINE+1]]:21: error: unexpected token in '.arch_extension' directive
127 .arch_extension mp $
128 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
129 .arch_extension mp @ EOL COMMENT
131 // CHECK: [[@LINE+1]]:21: error: unexpected token in '.arch_extension' directive
132 .arch_extension mp $
133 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
134 .arch_extension mp @ EOL COMMENT
136 .type arm_func,%function
137 arm_func:
139 // CHECK: [[@LINE+1]]:45: error: unexpected token
140 .thumb_set alias_arm_func, arm_func $
141 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
142 .thumb_set alias_arm_func, arm_func @ EOL COMMENT
144 // CHECK: [[@LINE+1]]:23: error: unexpected token in '.eabi_attribute' directive
145 .eabi_attribute 0, 0 $
146 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
147 .eabi_attribute 0, 0 @ EOL COMMENT
149 .arm
150 // CHECK: [[@LINE+1]]:10: error: unexpected token
151 .inst 2 $
152 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
153 .inst 2 @ EOL COMMENT
154 .thumb
155 // CHECK: [[@LINE+1]]:12: error: unexpected token
156 .inst.n 2 $
157 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
158 .inst.n 2 @ EOL COMMENT
159 // CHECK: [[@LINE+1]]:12: error: unexpected token
160 .inst.w 4 $
161 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
162 .inst.w 4 @ EOL COMMENT
163 // CHECK: [[@LINE+1]]:21: error: unexpected token
164 .object_arch armv7 $
165 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
166 .object_arch armv7 @ EOL COMMENT
167 // CHECK: [[@LINE+1]]:23: error: unexpected token in '.tlsdescseq' directive
168 .tlsdescseq variable $
169 // CHECK-NOT: [[@LINE+1]]:{{[0-9]+}}: error:
170 .tlsdescseq variable @ EOL COMMENT