1# RUN: llvm-mc --disassemble %s -triple=mips-unknown-linux | FileCheck %s
2
3# CHECK: abs.d $f12, $f14
40x46 0x20 0x73 0x05
5
6# CHECK: abs.s $f6, $f7
70x46 0x00 0x39 0x85
8
9# CHECK: add $9, $6, $7
100x00 0xc7 0x48 0x20
11
12# CHECK: add.d $f8, $f12, $f14
130x46 0x2e 0x62 0x00
14
15# CHECK: add.s $f9, $f6, $f7
160x46 0x07 0x32 0x40
17
18# CHECK: addi $9, $6, 17767
190x20 0xc9 0x45 0x67
20
21# CHECK: addiu $9, $6, -15001
220x24 0xc9 0xc5 0x67
23
24# CHECK: addu $9, $6, $7
250x00 0xc7 0x48 0x21
26
27# CHECK: and $9, $6, $7
280x00 0xc7 0x48 0x24
29
30# CHECK: andi $9, $6, 17767
310x30 0xc9 0x45 0x67
32
33# CHECK: b 1332
340x10 0x00 0x01 0x4c
35
36# CHECK: bc1f 1332
370x45 0x00 0x01 0x4c
38
39# CHECK: bc1f $fcc7, 1332
400x45 0x1c 0x01 0x4c
41
42# CHECK: bc1t 1332
430x45 0x01 0x01 0x4c
44
45# CHECK: bc1t $fcc7, 1332
460x45 0x1d 0x01 0x4c
47
48# CHECK: beq $9, $6, 1332
490x11 0x26 0x01 0x4c
50
51# CHECK: bgez  $6, 1332
520x04 0xc1 0x01 0x4c
53
54# CHECK: bgezal  $6, 1332
550x04 0xd1 0x01 0x4c
56
57# CHECK: bgtz  $6, 1332
580x1c 0xc0 0x01 0x4c
59
60# CHECK: blez  $6, 1332
610x18 0xc0 0x01 0x4c
62
63# CHECK: bne $9, $6, 1332
640x15 0x26 0x01 0x4c
65
66# CHECK: c.eq.d $f12, $f14
670x46 0x2e 0x60 0x32
68
69# CHECK: c.eq.s $f6, $f7
700x46 0x07 0x30 0x32
71
72# CHECK: c.f.d $f12, $f14
730x46 0x2e 0x60 0x30
74
75# CHECK: c.f.s $f6, $f7
760x46 0x07 0x30 0x30
77
78# CHECK: c.le.d $f12, $f14
790x46 0x2e 0x60 0x3e
80
81# CHECK: c.le.s $f6, $f7
820x46 0x07 0x30 0x3e
83
84# CHECK: c.lt.d $f12, $f14
850x46 0x2e 0x60 0x3c
86
87# CHECK: c.lt.s $f6, $f7
880x46 0x07 0x30 0x3c
89
90# CHECK: c.nge.d $f12, $f14
910x46 0x2e 0x60 0x3d
92
93# CHECK: c.nge.s $f6, $f7
940x46 0x07 0x30 0x3d
95
96# CHECK: c.ngl.d $f12, $f14
970x46 0x2e 0x60 0x3b
98
99# CHECK: c.ngl.s $f6, $f7
1000x46 0x07 0x30 0x3b
101
102# CHECK: c.ngle.d $f12, $f14
1030x46 0x2e 0x60 0x39
104
105# CHECK: c.ngle.s $f6, $f7
1060x46 0x07 0x30 0x39
107
108# CHECK: c.ngt.d $f12, $f14
1090x46 0x2e 0x60 0x3f
110
111# CHECK: c.ngt.s $f6, $f7
1120x46 0x07 0x30 0x3f
113
114# CHECK: c.ole.d $f12, $f14
1150x46 0x2e 0x60 0x36
116
117# CHECK: c.ole.s $f6, $f7
1180x46 0x07 0x30 0x36
119
120# CHECK: c.olt.d $f12, $f14
1210x46 0x2e 0x60 0x34
122
123# CHECK: c.olt.s $f6, $f7
1240x46 0x07 0x30 0x34
125
126# CHECK: c.seq.d $f12, $f14
1270x46 0x2e 0x60 0x3a
128
129# CHECK: c.seq.s $f6, $f7
1300x46 0x07 0x30 0x3a
131
132# CHECK: c.sf.d $f12, $f14
1330x46 0x2e 0x60 0x38
134
135# CHECK: c.sf.s $f6, $f7
1360x46 0x07 0x30 0x38
137
138# CHECK: c.ueq.d $f12, $f14
1390x46 0x2e 0x60 0x33
140
141# CHECK: c.ueq.s $f28, $f18
1420x46 0x12 0xe0 0x33
143
144# CHECK: c.ule.d $f12, $f14
1450x46 0x2e 0x60 0x37
146
147# CHECK: c.ule.s $f6, $f7
1480x46 0x07 0x30 0x37
149
150# CHECK: c.ult.d $f12, $f14
1510x46 0x2e 0x60 0x35
152
153# CHECK: c.ult.s $f6, $f7
1540x46 0x07 0x30 0x35
155
156# CHECK: c.un.d $f12, $f14
1570x46 0x2e 0x60 0x31
158
159# CHECK: c.un.s $f6, $f7
1600x46 0x07 0x30 0x31
161
162# CHECK: ceil.w.d $f12, $f14
1630x46 0x20 0x73 0x0e
164
165# CHECK: ceil.w.s $f6, $f7
1660x46 0x00 0x39 0x8e
167
168# CHECK: cfc1  $6, $7
1690x44 0x46 0x38 0x00
170
171# CHECK: clo  $6, $7
1720x70 0xe6 0x30 0x21
173
174# CHECK: clz  $6, $7
1750x70 0xe6 0x30 0x20
176
177# CHECK: ctc1  $6, $7
1780x44 0xc6 0x38 0x00
179
180# CHECK: cvt.d.s $f6, $f7
1810x46 0x00 0x39 0xa1
182
183# CHECK: cvt.d.w $f12, $f14
1840x46 0x80 0x73 0x21
185
186# CHECK: cvt.s.d $f12, $f14
1870x46 0x20 0x73 0x20
188
189# CHECK: cvt.s.w $f6, $f7
1900x46 0x80 0x39 0xa0
191
192# CHECK: cvt.w.d $f12, $f14
1930x46 0x20 0x73 0x24
194
195# CHECK: cvt.w.s $f6, $f7
1960x46 0x00 0x39 0xa4
197
198# CHECK: floor.w.d $f12, $f14
1990x46 0x20 0x73 0x0f
200
201# CHECK: floor.w.s $f6, $f7
2020x46 0x00 0x39 0x8f
203
204# CHECK: j 1328
2050x08 0x00 0x01 0x4c
206
207# CHECK: jal 1328
2080x0c 0x00 0x01 0x4c
209
210# CHECK: jalx 1328
2110x74 0x00 0x01 0x4c
212
213# CHECK: jalr  $7
2140x00 0xe0 0xf8 0x09
215
216# CHECK: jr  $7
2170x00 0xe0 0x00 0x08
218
219# CHECK: lb  $4, 9158($5)
2200x80 0xa4 0x23 0xc6
221
222# CHECK: lbu $4, 6($5)
2230x90 0xa4 0x00 0x06
224
225# CHECK: ldc1  $f9, 9158($7)
2260xd4 0xe9 0x23 0xc6
227
228# CHECK: lh  $4, 12($5)
2290x84 0xa4 0x00 0x0c
230
231# CHECK: lh  $4, 12($5)
2320x84 0xa4 0x00 0x0c
233
234# CHECK: ll  $9, 9158($7)
2350xc0 0xe9 0x23 0xc6
236
237# CHECK: lui  $6, 17767
2380x3c 0x06 0x45 0x67
239
240# CHECK: lw  $4, 24($5)
2410x8c 0xa4 0x00 0x18
242
243# CHECK: lwc1  $f9, 9158($7)
2440xc4 0xe9 0x23 0xc6
245
246# CHECK: lwl   $2,  3($4)
2470x88 0x82 0x00 0x03
248
249# CHECK: lwr   $3, 16($5)
2500x98 0xa3 0x00 0x10
251
252# CHECK: madd   $6,  $7
2530x70 0xc7 0x00 0x00
254
255# CHECK: maddu  $6,  $7
2560x70 0xc7 0x00 0x01
257
258# CHECK: mfc1   $6, $f7
2590x44 0x06 0x38 0x00
260
261# CHECK: mfhi  $5
2620x00 0x00 0x28 0x10
263
264# CHECK: mflo  $5
2650x00 0x00 0x28 0x12
266
267# CHECK: mov.d $f6, $f8
2680x46 0x20 0x41 0x86
269
270# CHECK: mov.s $f6, $f7
2710x46 0x00 0x39 0x86
272
273# CHECK: movf $3, $2, $fcc7
2740x00,0x5c,0x18,0x01
275
276# CHECK: movf.d $f4, $f2, $fcc7
2770x46,0x3c,0x11,0x11
278
279# CHECK: movf.s $f4, $f2, $fcc7
2800x46,0x1c,0x11,0x11
281
282# CHECK: movt $3, $2, $fcc7
2830x00,0x5d,0x18,0x01
284
285# CHECK: movt.d $f4, $f2, $fcc7
2860x46,0x3d,0x11,0x11
287
288# CHECK: movt.s $f4, $f2, $fcc7
2890x46,0x1d,0x11,0x11
290
291# CHECK: msub   $6,  $7
2920x70 0xc7 0x00 0x04
293
294# CHECK: msubu  $6,  $7
2950x70 0xc7 0x00 0x05
296
297# CHECK: mtc1   $6, $f7
2980x44 0x86 0x38 0x00
299
300# CHECK: mthi   $7
3010x00 0xe0 0x00 0x11
302
303# CHECK: mtlo   $7
3040x00 0xe0 0x00 0x13
305
306# CHECK: mul.d $f8, $f12, $f14
3070x46 0x2e 0x62 0x02
308
309# CHECK: mul.s $f9, $f6, $f7
3100x46 0x07 0x32 0x42
311
312# CHECK: mul $9,  $6,  $7
3130x70 0xc7 0x48 0x02
314
315# CHECK: mult  $3, $5
3160x00 0x65 0x00 0x18
317
318# CHECK: multu $3, $5
3190x00 0x65 0x00 0x19
320
321# CHECK: neg.d $f12, $f14
3220x46 0x20 0x73 0x07
323
324# CHECK: neg.s $f6, $f7
3250x46 0x00 0x39 0x87
326
327# CHECK: nop
3280x00 0x00 0x00 0x00
329
330# CHECK: nor $9,  $6, $7
3310x00 0xc7 0x48 0x27
332
333# CHECK: or  $3, $3, $5
3340x00 0x65 0x18 0x25
335
336# CHECK: ori $9,  $6, 17767
3370x34 0xc9 0x45 0x67
338
339# CHECK: round.w.d $f12, $f14
3400x46 0x20 0x73 0x0c
341
342# CHECK: round.w.s $f6, $f7
3430x46 0x00 0x39 0x8c
344
345# CHECK: sb  $4, 9158($5)
3460xa0 0xa4 0x23 0xc6
347
348# CHECK: sb  $4, 6($5)
3490xa0 0xa4 0x00 0x06
350
351# CHECK: sc  $9, 9158($7)
3520xe0 0xe9 0x23 0xc6
353
354# CHECK: sdc1  $f9, 9158($7)
3550xf4 0xe9 0x23 0xc6
356
357# CHECK: sh  $4, 9158($5)
3580xa4 0xa4 0x23 0xc6
359
360# CHECK: sll $4, $3, 7
3610x00 0x03 0x21 0xc0
362
363# CHECK: sllv  $2, $3, $5
3640x00 0xa3 0x10 0x04
365
366# CHECK: slt $3, $3, $5
3670x00 0x65 0x18 0x2a
368
369# CHECK: slti  $3, $3, 103
3700x28 0x63 0x00 0x67
371
372# CHECK: sltiu $3, $3, 103
3730x2c 0x63 0x00 0x67
374
375# CHECK: sltu  $3, $3, $5
3760x00 0x65 0x18 0x2b
377
378# CHECK: sqrt.d  $f12, $f14
3790x46 0x20 0x73 0x04
380
381# CHECK: sqrt.s  $f6, $f7
3820x46 0x00 0x39 0x84
383
384# CHECK: sra $4, $3, 7
3850x00 0x03 0x21 0xc3
386
387# CHECK: srav  $2, $3, $5
3880x00 0xa3 0x10 0x07
389
390# CHECK: srl $4, $3, 7
3910x00 0x03 0x21 0xc2
392
393# CHECK: srlv  $2, $3, $5
3940x00 0xa3 0x10 0x06
395
396# CHECK: sub.d $f8, $f12, $f14
3970x46 0x2e 0x62 0x01
398
399# CHECK: sub.s $f9, $f6, $f7
4000x46 0x07 0x32 0x41
401
402# CHECK: sub $9,  $6, $7
4030x00 0xc7 0x48 0x22
404
405# CHECK: subu  $4, $3, $5
4060x00 0x65 0x20 0x23
407
408# CHECK: sw  $4, 24($5)
4090xac 0xa4 0x00 0x18
410
411# CHECK: swc1  $f9, 9158($7)
4120xe4 0xe9 0x23 0xc6
413
414# CHECK: swl $4,  16($5)
4150xa8 0xa4 0x00 0x10
416
417# CHECK: swr $6, 16($7)
4180xb8 0xe6 0x00 0x10
419
420# CHECK: sync  7
4210x00 0x00 0x01 0xcf
422
423# CHECK: trunc.w.d $f12, $f14
4240x46 0x20 0x73 0x0d
425
426# CHECK: trunc.w.s $f6, $f7
4270x46 0x00 0x39 0x8d
428
429# CHECK: xor $3, $3, $5
4300x00 0x65 0x18 0x26
431
432# CHECK: xori  $9,  $6, 17767
4330x38 0xc9 0x45 0x67
434
435# CHECK: .set    push
436# CHECK: .set    mips32r2
437# CHECK: rdhwr   $5, $29
438# CHECK: .set    pop
4390x7c 0x05 0xe8 0x3b
440
441# CHECK: cache 1, 2($3)
4420xbc 0x61 0x00 0x02
443
444# CHECK: pref 3, 4($2)
4450xcc 0x43 0x00 0x04
446
447# CHECK: swc2  $9, 9158($7)
4480xe8 0xe9 0x23 0xc6
449
450# CHECK: lwc2  $8, 9162($6)
4510xc8 0xc8 0x23 0xca
452