This commit was generated by cvs2svn to track changes on a CVS vendor
[deliverable/binutils-gdb.git] / gas / testsuite / gas / m68k / operands.s
1 # Test handling of MIT and Motorola syntax operands
2 # If you change this file, see also op68000.d.
3 .text
4 .globl foo
5 foo:
6 | Data register direct
7 tstl %d0
8
9 | Address register direct
10 tstl %a0
11
12 | Address register indirect
13 tstl %a0@
14 tstl (%a0)
15
16 | Address register indirect with postincrement
17 tstl %a0@+
18 tstl (%a0)+
19
20 | Address register indirect with predecrement
21 tstl %a0@-
22 tstl -(%a0)
23
24 | Address register indirect with displacement
25 tstl %a0@(8)
26 tstl (8,%a0)
27 tstl 8(%a0)
28
29 | Address register indirect with index (8-bit displacement)
30 tstl %a0@(8,%d0)
31 tstl %a0@(8,%d0:w)
32 tstl %a0@(8,%d0:w:1)
33 tstl %a0@(8,%d0:w:2)
34 tstl %a0@(8,%d0:w:4)
35 tstl %a0@(8,%d0:w:8)
36 tstl %a0@(8,%d0:l)
37 tstl %a0@(8,%d0:l:1)
38 tstl %a0@(8,%d0:l:2)
39 tstl %a0@(8,%d0:l:4)
40 tstl %a0@(8,%d0:l:8)
41 tstl %a0@(%d0:w:2)
42 tstl (8,%a0,%d0)
43 tstl (8,%a0,%d0*1)
44 tstl (8,%a0,%d0*2)
45 tstl (8,%a0,%d0*4)
46 tstl (8,%a0,%d0*8)
47 tstl (8,%a0,%d0.w)
48 tstl (8,%a0,%d0.w*1)
49 tstl (8,%a0,%d0.w*2)
50 tstl (8,%a0,%d0.w*4)
51 tstl (8,%a0,%d0.w*8)
52 tstl (8,%a0,%d0.l)
53 tstl (8,%a0,%d0.l*1)
54 tstl (8,%a0,%d0.l*2)
55 tstl (8,%a0,%d0.l*4)
56 tstl (8,%a0,%d0.l*8)
57 tstl (8,%d0,%a0)
58 tstl (8,%a1.w*2,%a0)
59 tstl (8,%a1,%a0)
60 tstl 8(%a0,%d0.w*2)
61 tstl 8(%d0.w*2,%a0)
62 tstl 8(%a1.w*2,%a0)
63 tstl (%a0,%d0.w*2)
64 tstl (%d0.w*2,%a0)
65
66 | Address register indirect with index (base displacement)
67 tstl %a0@(1000,%d0:w:2)
68 tstl @(1000,%d0:w:2)
69 tstl @(%d0:w:2)
70 tstl @(1000)
71 tstl %a0@(100000)
72 tstl (1000,%a0,%d0.w*2)
73 tstl (1000,%d0,%a0)
74 tstl (1000,%a1.w*2,%a0)
75 tstl 1000(%a0,%d0.w*2)
76 tstl 1000(%d0,%a0)
77 tstl (1000,%d0.w*2)
78 tstl 1000(%d0.w*2)
79 tstl (%d0.w*2)
80 tstl (100000,%a0)
81 tstl 100000(%a0)
82 tstl %za1@(1000,%d0:w:2)
83 tstl %za1@(100000)
84 tstl (1000,%za1,%d0.w*2)
85 tstl (1000,%d0,%za1)
86 tstl (1000,%a1.w*2,%za1)
87 tstl 1000(%za1,%d0.w*2)
88 tstl 1000(%d0,%za1)
89 tstl (100000,%za1)
90 tstl 100000(%za1)
91 tstl %a0@(1000,%zd1:w:2)
92 tstl @(1000,%zd1:w:2)
93 tstl @(%zd1:w:2)
94 tstl (1000,%a0,%zd1.w*2)
95 tstl (1000,%zd1,%a0)
96 tstl (1000,%za1.w*2,%a0)
97 tstl 1000(%a0,%zd1.w*2)
98 tstl 1000(%zd1,%a0)
99 tstl (1000,%zd1.w*2)
100 tstl 1000(%zd1.w*2)
101 tstl (%zd1.w*2)
102
103 | Memory indirect postindexed
104 tstl %a0@(1000)@(2000,%d0:w:2)
105 tstl %a0@(1000)@(%d0:w:2)
106 tstl %a0@(1000)@(2000)
107 tstl @(1000)@(2000,%d0:w:2)
108 tstl @(1000)@(%d0:w:2)
109 tstl @(1000)@(2000)
110 tstl %a0@(0)@(2000,%d0:w:2)
111 tstl %a0@(0)@(%d0:w:2)
112 tstl %a0@(0)@(2000)
113 tstl @(0)@(2000,%d0:w:2)
114 tstl @(0)@(%d0:w:2)
115 tstl @(0)@(2000)
116 tstl ([1000,%a0],%d0:w:2,2000)
117 tstl ([1000,%a0],%d0:w:2)
118 tstl ([1000,%a0],2000)
119 tstl ([1000],%d0:w:2,2000)
120 tstl ([1000],%d0:w:2)
121 tstl ([1000],2000)
122 tstl ([%a0],%d0:w:2,2000)
123 tstl ([%a0],%d0:w:2)
124 tstl ([%a0],2000)
125 tstl ([0],%d0:w:2,2000)
126 tstl ([0],%d0:w:2)
127 tstl ([0],2000)
128
129 | Memory indirect preindexed
130 tstl %a0@(1000,%d0:w:2)@(2000)
131 tstl %a0@(1000,%d0:w:2)@(0)
132 tstl @(1000,%d0:w:2)@(2000)
133 tstl @(1000,%d0:w:2)@(0)
134 tstl %a0@(%d0:w:2)@(2000)
135 tstl %a0@(%d0:w:2)@(0)
136 tstl @(%d0:w:2)@(2000)
137 tstl @(%d0:w:2)@(0)
138 tstl ([1000,%a0,%d0:w:2],2000)
139 tstl ([1000,%d0:w:2,%a0],2000)
140 tstl ([1000,%d0,%a0],2000)
141 tstl ([1000,%a1,%a0],2000)
142 tstl ([1000,%a1:w:2,%a0],2000)
143 tstl ([1000,%a0,%d0:w:2])
144 tstl ([1000,%d0,%a0])
145 tstl ([1000,%d0:w:2],2000)
146 tstl ([1000,%d0:w:2])
147 tstl ([%a0,%d0:w:2],2000)
148 tstl ([%d0,%a0],2000)
149 tstl ([%a0,%d0:w:2])
150 tstl ([%d0,%a0])
151 tstl ([%d0:w:2],2000)
152 tstl ([%d0:w:2])
153
154 | Program counter indirect with displacement
155 tstl %pc@(8)
156 tstl (8,%pc)
157 tstl 8(%pc)
158 tstl foo
159
160 | Program counter indirect with index (8-bit displacement)
161 tstl %pc@(8,%d0:w:2)
162 tstl %pc@(%d0:w:2)
163 tstl (8,%pc,%d0.w*2)
164 tstl (8,%d0,%pc)
165 tstl (8,%a0,%pc)
166 tstl 8(%pc,%d0.w*2)
167 tstl 8(%d0,%pc)
168 tstl 8(%a0,%pc)
169 tstl (%pc,%d0.w*2)
170 tstl (%d0,%pc)
171 tstl (%a0,%pc)
172
173 | Program counter indirect with index (base displacement)
174 tstl %pc@(1000,%d0:w:2)
175 tstl %pc@(100000)
176 tstl (1000,%pc,%d0.w*2)
177 tstl (1000,%d0,%pc)
178 tstl (1000,%a1.w*2,%pc)
179 tstl (1000,%a1,%pc)
180 tstl 1000(%pc,%d0.w*2)
181 tstl 1000(%d0,%pc)
182 tstl 1000(%a1,%pc)
183 tstl (100000,%pc)
184 tstl 100000(%pc)
185 tstl %zpc@(1000,%d0:w:2)
186 tstl %zpc@(100000)
187 tstl (1000,%zpc,%d0.w*2)
188 tstl (1000,%d0,%zpc)
189 tstl (1000,%a1.w*2,%zpc)
190 tstl (1000,%a1,%zpc)
191 tstl 1000(%zpc,%d0.w*2)
192 tstl 1000(%d0,%zpc)
193 tstl 1000(%a1,%zpc)
194 tstl (100000,%zpc)
195 tstl 100000(%zpc)
196
197 | Program counter memory indirect postindexed
198 tstl %pc@(1000)@(2000,%d0:w:2)
199 tstl %pc@(1000)@(%d0:w:2)
200 tstl %pc@(1000)@(2000)
201 tstl %pc@(0)@(2000,%d0:w:2)
202 tstl %pc@(0)@(%d0:w:2)
203 tstl %pc@(0)@(2000)
204 tstl ([1000,%pc],%d0:w:2,2000)
205 tstl ([1000,%pc],%d0:w:2)
206 tstl ([1000,%pc],2000)
207 tstl ([%pc],%d0:w:2,2000)
208 tstl ([%pc],%d0:w:2)
209 tstl ([%pc],2000)
210 tstl %zpc@(1000)@(2000,%d0:w:2)
211 tstl %zpc@(1000)@(%d0:w:2)
212 tstl %zpc@(1000)@(2000)
213 tstl %zpc@(0)@(2000,%d0:w:2)
214 tstl %zpc@(0)@(%d0:w:2)
215 tstl %zpc@(0)@(2000)
216 tstl ([1000,%zpc],%d0:w:2,2000)
217 tstl ([1000,%zpc],%d0:w:2)
218 tstl ([1000,%zpc],2000)
219 tstl ([%zpc],%d0:w:2,2000)
220 tstl ([%zpc],%d0:w:2)
221 tstl ([%zpc],2000)
222
223 | Program counter memory indirect preindexed
224 tstl %pc@(1000,%d0:w:2)@(2000)
225 tstl %pc@(1000,%d0:w:2)@(0)
226 tstl %pc@(%d0:w:2)@(2000)
227 tstl %pc@(%d0:w:2)@(0)
228 tstl ([1000,%pc,%d0:w:2],2000)
229 tstl ([1000,%d0:w:2,%pc],2000)
230 tstl ([1000,%d0,%pc],2000)
231 tstl ([1000,%a1,%pc],2000)
232 tstl ([1000,%pc,%a1],2000)
233 tstl ([1000,%a1:w:2,%pc],2000)
234 tstl ([1000,%pc,%d0:w:2])
235 tstl ([1000,%d0,%pc])
236 tstl ([1000,%a1,%pc])
237 tstl ([%pc,%d0:w:2],2000)
238 tstl ([%pc,%a0],2000)
239 tstl ([%pc,%d0:w:2])
240 tstl ([%d0,%pc])
241 tstl %zpc@(1000,%d0:w:2)@(2000)
242 tstl %zpc@(1000,%d0:w:2)@(0)
243 tstl %zpc@(%d0:w:2)@(2000)
244 tstl %zpc@(%d0:w:2)@(0)
245 tstl ([1000,%zpc,%d0:w:2],2000)
246 tstl ([1000,%d0:w:2,%zpc],2000)
247 tstl ([1000,%d0,%zpc],2000)
248 tstl ([1000,%a1,%zpc],2000)
249 tstl ([1000,%zpc,%a1],2000)
250 tstl ([1000,%a1:w:2,%zpc],2000)
251 tstl ([1000,%zpc,%d0:w:2])
252 tstl ([1000,%d0,%zpc])
253 tstl ([1000,%a1,%zpc])
254 tstl ([%zpc,%d0:w:2],2000)
255 tstl ([%zpc,%a0],2000)
256 tstl ([%zpc,%d0:w:2])
257 tstl ([%d0,%zpc])
258
259 | Absolute short
260 tstl 4
261 tstl 4.w
262 tstl (4).w
263
264 | Absolute long
265 tstl 100000
266 tstl 8.l
267 tstl (8).l
268
269 | Immediate
270 addib #1,%d0
271 addiw #1,%d0
272 addil #1,%d0
273 addqb #1,%d0
This page took 0.037256 seconds and 5 git commands to generate.