Taints the non-acquire RMW's store address with the load part
[oota-llvm.git] / test / MC / Sparc / sparcv9-instructions.s
1 ! RUN: not llvm-mc %s -arch=sparc   -show-encoding 2>&1 | FileCheck %s --check-prefix=V8
2 ! RUN: llvm-mc %s -arch=sparcv9 -show-encoding | FileCheck %s --check-prefix=V9
3
4         ! V8:      error: invalid instruction mnemonic
5         ! V8-NEXT: addc %g2, %g1, %g3
6         ! V9:      addx %g2, %g1, %g3              ! encoding: [0x86,0x40,0x80,0x01]
7         addc %g2, %g1, %g3
8
9         ! V8:      error: invalid instruction mnemonic
10         ! V8-NEXT: addccc %g1, %g2, %g3
11         ! V9:      addxcc %g1, %g2, %g3            ! encoding: [0x86,0xc0,0x40,0x02]
12         addccc %g1, %g2, %g3
13
14         ! V8:      error: invalid instruction mnemonic
15         ! V8-NEXT: subc %g2, %g1, %g3
16         ! V9:      subx %g2, %g1, %g3          ! encoding: [0x86,0x60,0x80,0x01]
17         subc %g2, %g1, %g3
18
19         ! V8:      error: invalid instruction mnemonic
20         ! V8-NEXT: subccc %g1, %g2, %g3
21         ! V9:      subxcc %g1, %g2, %g3         ! encoding: [0x86,0xe0,0x40,0x02]
22         subccc %g1, %g2, %g3
23
24         ! V8:      error: instruction requires a CPU feature not currently enabled
25         ! V8-NEXT: popc %g1, %g2
26         ! V9:      popc %g1, %g2                ! encoding: [0x85,0x70,0x00,0x01]
27         popc %g1, %g2
28
29
30         ! V8:      error: instruction requires a CPU feature not currently enabled
31         ! V8-NEXT: signx %g1, %g2
32         ! V9: sra %g1, %g0, %g2               ! encoding: [0x85,0x38,0x40,0x00]
33         signx %g1, %g2
34         ! V8:      error: instruction requires a CPU feature not currently enabled
35         ! V8-NEXT: signx %g1
36         ! V9: sra %g1, %g0, %g1               ! encoding: [0x83,0x38,0x40,0x00]
37         signx %g1
38
39         ! V8:      error: invalid instruction mnemonic
40         ! V8-NEXT: lduw [%i0 + %l6], %o2
41         ! V9: ld [%i0+%l6], %o2    ! encoding: [0xd4,0x06,0x00,0x16]
42         lduw [%i0 + %l6], %o2
43         ! V8:      error: invalid instruction mnemonic
44         ! V8-NEXT: lduw [%i0 + 32], %o2
45         ! V9: ld [%i0+32], %o2     ! encoding: [0xd4,0x06,0x20,0x20]
46         lduw [%i0 + 32], %o2
47         ! V8:      error: invalid instruction mnemonic
48         ! V8-NEXT: lduw [%g1], %o2
49         ! V9: ld [%g1], %o2        ! encoding: [0xd4,0x00,0x40,0x00]
50         lduw [%g1], %o2
51         ! V8:      error: invalid instruction mnemonic
52         ! V8-NEXT: lduwa [%i0 + %l6] 131, %o2
53         ! V9: lda [%i0+%l6] 131, %o2 ! encoding: [0xd4,0x86,0x10,0x76]
54         lduwa [%i0 + %l6] 131, %o2
55
56         ! V8:      error: instruction requires a CPU feature not currently enabled
57         ! V8-NEXT: lda [%l0] 0xf0, %f29
58         ! V9: lda [%l0] 240, %f29             ! encoding: [0xfb,0x84,0x1e,0x00]
59         lda [%l0] 0xf0, %f29
60
61         ! V8:      error: instruction requires a CPU feature not currently enabled
62         ! V8-NEXT: ldda [%l0] 0xf0, %f48
63         ! V9: ldda [%l0] 240, %f48            ! encoding: [0xe3,0x9c,0x1e,0x00]
64         ldda [%l0] 0xf0, %f48
65
66         ! V8:      error: instruction requires a CPU feature not currently enabled
67         ! V8-NEXT: ldqa [%l0] 0xf0, %f48
68         ! V8:      error: instruction requires a CPU feature not currently enabled
69         ! V8-NEXT: ldq [%l0], %f48
70         ! V9: ldqa [%l0] 240, %f48            ! encoding: [0xe3,0x94,0x1e,0x00]
71         ! V9: ldq [%l0], %f48                 ! encoding: [0xe3,0x14,0x00,0x00]
72         ldqa [%l0] 0xf0, %f48
73         ldq [%l0], %f48
74
75         ! V8:      error: instruction requires a CPU feature not currently enabled
76         ! V8-NEXT: sta %f29, [%l0] 0xf0
77         ! V9: sta %f29, [%l0] 240             ! encoding: [0xfb,0xa4,0x1e,0x00]
78         sta %f29, [%l0] 0xf0
79
80         ! V8:      error: instruction requires a CPU feature not currently enabled
81         ! V8-NEXT: stda %f48, [%l0] 0xf0
82         ! V9: stda %f48, [%l0] 240            ! encoding: [0xe3,0xbc,0x1e,0x00]
83         stda %f48, [%l0] 0xf0
84
85         ! V8:      error: instruction requires a CPU feature not currently enabled
86         ! V8-NEXT: stqa %f48, [%l0] 0xf0
87         ! V8:      error: instruction requires a CPU feature not currently enabled
88         ! V8-NEXT: stq %f48, [%l0]
89         ! V9: stqa %f48, [%l0] 240            ! encoding: [0xe3,0xb4,0x1e,0x00]
90         ! V9: stq %f48, [%l0]                 ! encoding: [0xe3,0x34,0x00,0x00]
91         stqa %f48, [%l0] 0xf0
92         stq %f48, [%l0]
93
94         ! V8:      error: instruction requires a CPU feature not currently enabled
95         ! V8-NEXT: ldx [%g2 + 20],%fsr
96         ! V9: ldx [%g2+20], %fsr    ! encoding: [0xc3,0x08,0xa0,0x14]
97         ldx [%g2 + 20],%fsr
98
99         ! V8:      error: instruction requires a CPU feature not currently enabled
100         ! V8-NEXT: ldx [%g2 + %i5],%fsr
101         ! V9: ldx [%g2+%i5], %fsr   ! encoding: [0xc3,0x08,0x80,0x1d]
102         ldx [%g2 + %i5],%fsr
103
104         ! V8:      error: instruction requires a CPU feature not currently enabled
105         ! V8-NEXT: stx %fsr,[%g2 + 20]
106         ! V9: stx %fsr, [%g2+20]    ! encoding: [0xc3,0x28,0xa0,0x14]
107         stx %fsr,[%g2 + 20]
108
109         ! V8:      error: instruction requires a CPU feature not currently enabled
110         ! V8-NEXT: stx %fsr,[%g2 + %i5]
111         ! V9: stx %fsr, [%g2+%i5]   ! encoding: [0xc3,0x28,0x80,0x1d]
112         stx %fsr,[%g2 + %i5]
113
114         ! V8:      error: instruction requires a CPU feature not currently enabled
115         ! V8-NEXT: wrpr %g6,%i6,%tpc
116         ! V9: wrpr %g6, %fp, %tpc        ! encoding: [0x81,0x91,0x80,0x1e]
117         wrpr %g6,%i6,%tpc
118         ! V8:      error: instruction requires a CPU feature not currently enabled
119         ! V8-NEXT: wrpr %g6,%i6,%tnpc
120         ! V9: wrpr %g6, %fp, %tnpc       ! encoding: [0x83,0x91,0x80,0x1e]
121         wrpr %g6,%i6,%tnpc
122         ! V8:      error: instruction requires a CPU feature not currently enabled
123         ! V8-NEXT: wrpr %g6,%i6,%tstate
124         ! V9: wrpr %g6, %fp, %tstate     ! encoding: [0x85,0x91,0x80,0x1e]
125         wrpr %g6,%i6,%tstate
126         ! V8:      error: instruction requires a CPU feature not currently enabled
127         ! V8-NEXT: wrpr %g6,%i6,%tt
128         ! V9: wrpr %g6, %fp, %tt         ! encoding: [0x87,0x91,0x80,0x1e]
129         wrpr %g6,%i6,%tt
130         ! V8:      error: instruction requires a CPU feature not currently enabled
131         ! V8-NEXT: wrpr %g6,%i6,%tick
132         ! V9: wrpr %g6, %fp, %tick       ! encoding: [0x89,0x91,0x80,0x1e]
133         wrpr %g6,%i6,%tick
134         ! V8:      error: instruction requires a CPU feature not currently enabled
135         ! V8-NEXT: wrpr %g6,%i6,%tba
136         ! V9: wrpr %g6, %fp, %tba        ! encoding: [0x8b,0x91,0x80,0x1e]
137         wrpr %g6,%i6,%tba
138         ! V8:      error: instruction requires a CPU feature not currently enabled
139         ! V8-NEXT: wrpr %g6,%i6,%pstate
140         ! V9: wrpr %g6, %fp, %pstate     ! encoding: [0x8d,0x91,0x80,0x1e]
141         wrpr %g6,%i6,%pstate
142         ! V8:      error: instruction requires a CPU feature not currently enabled
143         ! V8-NEXT: wrpr %g6,%i6,%tl
144         ! V9: wrpr %g6, %fp, %tl         ! encoding: [0x8f,0x91,0x80,0x1e]
145         wrpr %g6,%i6,%tl
146         ! V8:      error: instruction requires a CPU feature not currently enabled
147         ! V8-NEXT: wrpr %g6,%i6,%pil
148         ! V9: wrpr %g6, %fp, %pil        ! encoding: [0x91,0x91,0x80,0x1e]
149         wrpr %g6,%i6,%pil
150         ! V8:      error: instruction requires a CPU feature not currently enabled
151         ! V8-NEXT: wrpr %g6,%i6,%cwp
152         ! V9: wrpr %g6, %fp, %cwp        ! encoding: [0x93,0x91,0x80,0x1e]
153         wrpr %g6,%i6,%cwp
154         ! V8:      error: instruction requires a CPU feature not currently enabled
155         ! V8-NEXT: wrpr %g6,%i6,%cansave
156         ! V9: wrpr %g6, %fp, %cansave    ! encoding: [0x95,0x91,0x80,0x1e]
157         wrpr %g6,%i6,%cansave
158         ! V8:      error: instruction requires a CPU feature not currently enabled
159         ! V8-NEXT: wrpr %g6,%i6,%canrestore
160         ! V9: wrpr %g6, %fp, %canrestore ! encoding: [0x97,0x91,0x80,0x1e]
161         wrpr %g6,%i6,%canrestore
162         ! V8:      error: instruction requires a CPU feature not currently enabled
163         ! V8-NEXT: wrpr %g6,%i6,%cleanwin
164         ! V9: wrpr %g6, %fp, %cleanwin   ! encoding: [0x99,0x91,0x80,0x1e]
165         wrpr %g6,%i6,%cleanwin
166         ! V8:      error: instruction requires a CPU feature not currently enabled
167         ! V8-NEXT: wrpr %g6,%i6,%otherwin
168         ! V9: wrpr %g6, %fp, %otherwin   ! encoding: [0x9b,0x91,0x80,0x1e]
169         wrpr %g6,%i6,%otherwin
170         ! V8:      error: instruction requires a CPU feature not currently enabled
171         ! V8-NEXT: wrpr %g6,%i6,%wstate
172         ! V9: wrpr %g6, %fp, %wstate     ! encoding: [0x9d,0x91,0x80,0x1e]
173         wrpr %g6,%i6,%wstate
174
175         ! V8:      error: instruction requires a CPU feature not currently enabled
176         ! V8-NEXT: wrpr %g6,255,%tpc
177         ! V9: wrpr %g6, 255, %tpc        ! encoding: [0x81,0x91,0xa0,0xff]
178         wrpr %g6,255,%tpc
179         ! V8:      error: instruction requires a CPU feature not currently enabled
180         ! V8-NEXT: wrpr %g6,255,%tnpc
181         ! V9: wrpr %g6, 255, %tnpc       ! encoding: [0x83,0x91,0xa0,0xff]
182         wrpr %g6,255,%tnpc
183         ! V8:      error: instruction requires a CPU feature not currently enabled
184         ! V8-NEXT: wrpr %g6,255,%tstate
185         ! V9: wrpr %g6, 255, %tstate     ! encoding: [0x85,0x91,0xa0,0xff]
186         wrpr %g6,255,%tstate
187         ! V8:      error: instruction requires a CPU feature not currently enabled
188         ! V8-NEXT: wrpr %g6,255,%tt
189         ! V9: wrpr %g6, 255, %tt         ! encoding: [0x87,0x91,0xa0,0xff]
190         wrpr %g6,255,%tt
191         ! V8:      error: instruction requires a CPU feature not currently enabled
192         ! V8-NEXT: wrpr %g6,255,%tick
193         ! V9: wrpr %g6, 255, %tick       ! encoding: [0x89,0x91,0xa0,0xff]
194         wrpr %g6,255,%tick
195         ! V8:      error: instruction requires a CPU feature not currently enabled
196         ! V8-NEXT: wrpr %g6,255,%tba
197         ! V9: wrpr %g6, 255, %tba        ! encoding: [0x8b,0x91,0xa0,0xff]
198         wrpr %g6,255,%tba
199         ! V8:      error: instruction requires a CPU feature not currently enabled
200         ! V8-NEXT: wrpr %g6,255,%pstate
201         ! V9: wrpr %g6, 255, %pstate     ! encoding: [0x8d,0x91,0xa0,0xff]
202         wrpr %g6,255,%pstate
203         ! V8:      error: instruction requires a CPU feature not currently enabled
204         ! V8-NEXT: wrpr %g6,255,%tl
205         ! V9: wrpr %g6, 255, %tl         ! encoding: [0x8f,0x91,0xa0,0xff]
206         wrpr %g6,255,%tl
207         ! V8:      error: instruction requires a CPU feature not currently enabled
208         ! V8-NEXT: wrpr %g6,255,%pil
209         ! V9: wrpr %g6, 255, %pil        ! encoding: [0x91,0x91,0xa0,0xff]
210         wrpr %g6,255,%pil
211         ! V8:      error: instruction requires a CPU feature not currently enabled
212         ! V8-NEXT: wrpr %g6,255,%cwp
213         ! V9: wrpr %g6, 255, %cwp        ! encoding: [0x93,0x91,0xa0,0xff]
214         wrpr %g6,255,%cwp
215         ! V8:      error: instruction requires a CPU feature not currently enabled
216         ! V8-NEXT: wrpr %g6,255,%cansave
217         ! V9: wrpr %g6, 255, %cansave    ! encoding: [0x95,0x91,0xa0,0xff]
218         wrpr %g6,255,%cansave
219         ! V8:      error: instruction requires a CPU feature not currently enabled
220         ! V8-NEXT: wrpr %g6,255,%canrestore
221         ! V9: wrpr %g6, 255, %canrestore ! encoding: [0x97,0x91,0xa0,0xff]
222         wrpr %g6,255,%canrestore
223         ! V8:      error: instruction requires a CPU feature not currently enabled
224         ! V8-NEXT: wrpr %g6,255,%cleanwin
225         ! V9: wrpr %g6, 255, %cleanwin   ! encoding: [0x99,0x91,0xa0,0xff]
226         wrpr %g6,255,%cleanwin
227         ! V8:      error: instruction requires a CPU feature not currently enabled
228         ! V8-NEXT: wrpr %g6,255,%otherwin
229         ! V9: wrpr %g6, 255, %otherwin   ! encoding: [0x9b,0x91,0xa0,0xff]
230         wrpr %g6,255,%otherwin
231         ! V8:      error: instruction requires a CPU feature not currently enabled
232         ! V8-NEXT: wrpr %g6,255,%wstate
233         ! V9: wrpr %g6, 255, %wstate     ! encoding: [0x9d,0x91,0xa0,0xff]
234         wrpr %g6,255,%wstate
235
236         ! V8:      error: instruction requires a CPU feature not currently enabled
237         ! V8-NEXT: rdpr %tpc,%i5
238         ! V9: rdpr %tpc, %i5            ! encoding: [0xbb,0x50,0x00,0x00]
239         rdpr %tpc,%i5
240         ! V8:      error: instruction requires a CPU feature not currently enabled
241         ! V8-NEXT: rdpr %tnpc,%i5
242         ! V9: rdpr %tnpc, %i5           ! encoding: [0xbb,0x50,0x40,0x00]
243         rdpr %tnpc,%i5
244         ! V8:      error: instruction requires a CPU feature not currently enabled
245         ! V8-NEXT: rdpr %tstate,%i5
246         ! V9: rdpr %tstate, %i5         ! encoding: [0xbb,0x50,0x80,0x00]
247         rdpr %tstate,%i5
248         ! V8:      error: instruction requires a CPU feature not currently enabled
249         ! V8-NEXT: rdpr %tt,%i5
250         ! V9: rdpr %tt, %i5             ! encoding: [0xbb,0x50,0xc0,0x00]
251         rdpr %tt,%i5
252         ! V8:      error: instruction requires a CPU feature not currently enabled
253         ! V8-NEXT: rdpr %tick,%i5
254         ! V9: rdpr %tick, %i5           ! encoding: [0xbb,0x51,0x00,0x00]
255         rdpr %tick,%i5
256         ! V8:      error: instruction requires a CPU feature not currently enabled
257         ! V8-NEXT: rdpr %tba,%i5
258         ! V9: rdpr %tba, %i5            ! encoding: [0xbb,0x51,0x40,0x00]
259         rdpr %tba,%i5
260         ! V8:      error: instruction requires a CPU feature not currently enabled
261         ! V8-NEXT: rdpr %pstate,%i5
262         ! V9: rdpr %pstate, %i5         ! encoding: [0xbb,0x51,0x80,0x00]
263         rdpr %pstate,%i5
264         ! V8:      error: instruction requires a CPU feature not currently enabled
265         ! V8-NEXT: rdpr %tl,%i5
266         ! V9: rdpr %tl, %i5             ! encoding: [0xbb,0x51,0xc0,0x00]
267         rdpr %tl,%i5
268         ! V8:      error: instruction requires a CPU feature not currently enabled
269         ! V8-NEXT: rdpr %pil,%i5
270         ! V9: rdpr %pil, %i5            ! encoding: [0xbb,0x52,0x00,0x00]
271         rdpr %pil,%i5
272         ! V8:      error: instruction requires a CPU feature not currently enabled
273         ! V8-NEXT: rdpr %cwp,%i5
274         ! V9: rdpr %cwp, %i5            ! encoding: [0xbb,0x52,0x40,0x00]
275         rdpr %cwp,%i5
276         ! V8:      error: instruction requires a CPU feature not currently enabled
277         ! V8-NEXT: rdpr %cansave,%i5
278         ! V9: rdpr %cansave, %i5        ! encoding: [0xbb,0x52,0x80,0x00]
279         rdpr %cansave,%i5
280         ! V8:      error: instruction requires a CPU feature not currently enabled
281         ! V8-NEXT: rdpr %canrestore,%i5
282         ! V9: rdpr %canrestore, %i5     ! encoding: [0xbb,0x52,0xc0,0x00]
283         rdpr %canrestore,%i5
284         ! V8:      error: instruction requires a CPU feature not currently enabled
285         ! V8-NEXT: rdpr %cleanwin,%i5
286         ! V9: rdpr %cleanwin, %i5       ! encoding: [0xbb,0x53,0x00,0x00]
287         rdpr %cleanwin,%i5
288         ! V8:      error: instruction requires a CPU feature not currently enabled
289         ! V8-NEXT: rdpr %otherwin,%i5
290         ! V9: rdpr %otherwin, %i5       ! encoding: [0xbb,0x53,0x40,0x00]
291         rdpr %otherwin,%i5
292         ! V8:      error: instruction requires a CPU feature not currently enabled
293         ! V8-NEXT: rdpr %wstate,%i5
294         ! V9: rdpr %wstate, %i5         ! encoding: [0xbb,0x53,0x80,0x00]
295         rdpr %wstate,%i5