• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# RUN: llvm-mc --disassemble %s -triple powerpc64-unknown-unknown -mcpu=pwr7 | FileCheck %s
2
3# FIXME: test b target
4
5# FIXME: test ba target
6
7# FIXME: test bl target
8
9# FIXME: test bla target
10
11# FIXME: test bc 4, 10, target
12
13# FIXME: test bca 4, 10, target
14
15# FIXME: test bcl 4, 10, target
16
17# FIXME: test bcla 4, 10, target
18
19# CHECK: bclr 4, 10, 3
200x4c 0x8a 0x18 0x20
21
22# CHECK: bclr 4, 10
230x4c 0x8a 0x00 0x20
24
25# CHECK: bclrl 4, 10, 3
260x4c 0x8a 0x18 0x21
27
28# CHECK: bclrl 4, 10
290x4c 0x8a 0x00 0x21
30
31# CHECK: bcctr 4, 10, 3
320x4c 0x8a 0x1c 0x20
33
34# CHECK: bcctr 4, 10
350x4c 0x8a 0x04 0x20
36
37# CHECK: bcctrl 4, 10, 3
380x4c 0x8a 0x1c 0x21
39
40# CHECK: bcctrl 4, 10
410x4c 0x8a 0x04 0x21
42
43# CHECK: crand 2, 3, 4
440x4c 0x43 0x22 0x02
45
46# CHECK: crnand 2, 3, 4
470x4c 0x43 0x21 0xc2
48
49# CHECK: cror 2, 3, 4
500x4c 0x43 0x23 0x82
51
52# CHECK: crxor 2, 3, 4
530x4c 0x43 0x21 0x82
54
55# CHECK: crnor 2, 3, 4
560x4c 0x43 0x20 0x42
57
58# CHECK: creqv 2, 3, 4
590x4c 0x43 0x22 0x42
60
61# CHECK: crandc 2, 3, 4
620x4c 0x43 0x21 0x02
63
64# CHECK: crorc 2, 3, 4
650x4c 0x43 0x23 0x42
66
67# CHECK: mcrf 2, 3
680x4d 0x0c 0x00 0x00
69
70# CHECK: sc 1
710x44 0x00 0x00 0x22
72
73# CHECK: sc
740x44 0x00 0x00 0x02
75
76# CHECK: clrbhrb
770x7c 0x00 0x03 0x5c
78
79# CHECK: mfbhrbe 9, 983
800x7d 0x3e 0xba 0x5c
81
82# CHECK: rfebb 1
830x4c 0x00 0x09 0x24
84
85# CHECK: lbz 2, 128(4)
860x88 0x44 0x00 0x80
87
88# CHECK: lbzx 2, 3, 4
890x7c 0x43 0x20 0xae
90
91# CHECK: lbzu 2, 128(4)
920x8c 0x44 0x00 0x80
93
94# CHECK: lbzux 2, 3, 4
950x7c 0x43 0x20 0xee
96
97# CHECK: lhz 2, 128(4)
980xa0 0x44 0x00 0x80
99
100# CHECK: lhzx 2, 3, 4
1010x7c 0x43 0x22 0x2e
102
103# CHECK: lhzu 2, 128(4)
1040xa4 0x44 0x00 0x80
105
106# CHECK: lhzux 2, 3, 4
1070x7c 0x43 0x22 0x6e
108
109# CHECK: lha 2, 128(4)
1100xa8 0x44 0x00 0x80
111
112# CHECK: lhax 2, 3, 4
1130x7c 0x43 0x22 0xae
114
115# CHECK: lhau 2, 128(4)
1160xac 0x44 0x00 0x80
117
118# CHECK: lhaux 2, 3, 4
1190x7c 0x43 0x22 0xee
120
121# CHECK: lwz 2, 128(4)
1220x80 0x44 0x00 0x80
123
124# CHECK: lwzx 2, 3, 4
1250x7c 0x43 0x20 0x2e
126
127# CHECK: lwzu 2, 128(4)
1280x84 0x44 0x00 0x80
129
130# CHECK: lwzux 2, 3, 4
1310x7c 0x43 0x20 0x6e
132
133# CHECK: lwa 2, 128(4)
1340xe8 0x44 0x00 0x82
135
136# CHECK: lwax 2, 3, 4
1370x7c 0x43 0x22 0xaa
138
139# CHECK: lwaux 2, 3, 4
1400x7c 0x43 0x22 0xea
141
142# CHECK: ld 2, 128(4)
1430xe8 0x44 0x00 0x80
144
145# CHECK: ldx 2, 3, 4
1460x7c 0x43 0x20 0x2a
147
148# CHECK: ldu 2, 128(4)
1490xe8 0x44 0x00 0x81
150
151# CHECK: ldux 2, 3, 4
1520x7c 0x43 0x20 0x6a
153
154# CHECK: ldmx 2, 3, 4
1550x7c 0x43 0x22 0x6a
156
157# CHECK: stb 2, 128(4)
1580x98 0x44 0x00 0x80
159
160# CHECK: stbx 2, 3, 4
1610x7c 0x43 0x21 0xae
162
163# CHECK: stbu 2, 128(4)
1640x9c 0x44 0x00 0x80
165
166# CHECK: stbux 2, 3, 4
1670x7c 0x43 0x21 0xee
168
169# CHECK: sth 2, 128(4)
1700xb0 0x44 0x00 0x80
171
172# CHECK: sthx 2, 3, 4
1730x7c 0x43 0x23 0x2e
174
175# CHECK: sthu 2, 128(4)
1760xb4 0x44 0x00 0x80
177
178# CHECK: sthux 2, 3, 4
1790x7c 0x43 0x23 0x6e
180
181# CHECK: stw 2, 128(4)
1820x90 0x44 0x00 0x80
183
184# CHECK: stwx 2, 3, 4
1850x7c 0x43 0x21 0x2e
186
187# CHECK: stwu 2, 128(4)
1880x94 0x44 0x00 0x80
189
190# CHECK: stwux 2, 3, 4
1910x7c 0x43 0x21 0x6e
192
193# CHECK: std 2, 128(4)
1940xf8 0x44 0x00 0x80
195
196# CHECK: stdx 2, 3, 4
1970x7c 0x43 0x21 0x2a
198
199# CHECK: stdu 2, 128(4)
2000xf8 0x44 0x00 0x81
201
202# CHECK: stdux 2, 3, 4
2030x7c 0x43 0x21 0x6a
204
205# CHECK: lhbrx 2, 3, 4
2060x7c 0x43 0x26 0x2c
207
208# CHECK: sthbrx 2, 3, 4
2090x7c 0x43 0x27 0x2c
210
211# CHECK: lwbrx 2, 3, 4
2120x7c 0x43 0x24 0x2c
213
214# CHECK: stwbrx 2, 3, 4
2150x7c 0x43 0x25 0x2c
216
217# CHECK: ldbrx 2, 3, 4
2180x7c 0x43 0x24 0x28
219
220# CHECK: stdbrx 2, 3, 4
2210x7c 0x43 0x25 0x28
222
223# CHECK: lmw 2, 128(1)
2240xb8 0x41 0x00 0x80
225
226# CHECK: stmw 2, 128(1)
2270xbc 0x41 0x00 0x80
228
229# CHECK: addi 2, 3, 128
2300x38 0x43 0x00 0x80
231
232# CHECK: addis 2, 3, 128
2330x3c 0x43 0x00 0x80
234
235# CHECK: add 2, 3, 4
2360x7c 0x43 0x22 0x14
237
238# CHECK: add. 2, 3, 4
2390x7c 0x43 0x22 0x15
240
241# CHECK: subf 2, 3, 4
2420x7c 0x43 0x20 0x50
243
244# CHECK: subf. 2, 3, 4
2450x7c 0x43 0x20 0x51
246
247# CHECK: addic 2, 3, 128
2480x30 0x43 0x00 0x80
249
250# CHECK: addic. 2, 3, 128
2510x34 0x43 0x00 0x80
252
253# CHECK: subfic 2, 3, 4
2540x20 0x43 0x00 0x04
255
256# CHECK: addc 2, 3, 4
2570x7c 0x43 0x20 0x14
258
259# CHECK: addc. 2, 3, 4
2600x7c 0x43 0x20 0x15
261
262# CHECK: subfc 2, 3, 4
2630x7c 0x43 0x20 0x10
264
265# CHECK: subfc 2, 3, 4
2660x7c 0x43 0x20 0x10
267
268# CHECK: adde 2, 3, 4
2690x7c 0x43 0x21 0x14
270
271# CHECK: adde. 2, 3, 4
2720x7c 0x43 0x21 0x15
273
274# CHECK: subfe 2, 3, 4
2750x7c 0x43 0x21 0x10
276
277# CHECK: subfe. 2, 3, 4
2780x7c 0x43 0x21 0x11
279
280# CHECK: addme 2, 3
2810x7c 0x43 0x01 0xd4
282
283# CHECK: addme. 2, 3
2840x7c 0x43 0x01 0xd5
285
286# CHECK: subfme 2, 3
2870x7c 0x43 0x01 0xd0
288
289# CHECK: subfme. 2, 3
2900x7c 0x43 0x01 0xd1
291
292# CHECK: addze 2, 3
2930x7c 0x43 0x01 0x94
294
295# CHECK: addze. 2, 3
2960x7c 0x43 0x01 0x95
297
298# CHECK: subfze 2, 3
2990x7c 0x43 0x01 0x90
300
301# CHECK: subfze. 2, 3
3020x7c 0x43 0x01 0x91
303
304# CHECK: neg 2, 3
3050x7c 0x43 0x00 0xd0
306
307# CHECK: neg. 2, 3
3080x7c 0x43 0x00 0xd1
309
310# CHECK: mulli 2, 3, 128
3110x1c 0x43 0x00 0x80
312
313# CHECK: mulhw 2, 3, 4
3140x7c 0x43 0x20 0x96
315
316# CHECK: mulhw. 2, 3, 4
3170x7c 0x43 0x20 0x97
318
319# CHECK: mullw 2, 3, 4
3200x7c 0x43 0x21 0xd6
321
322# CHECK: mullw. 2, 3, 4
3230x7c 0x43 0x21 0xd7
324
325# CHECK: mulhwu 2, 3, 4
3260x7c 0x43 0x20 0x16
327
328# CHECK: mulhwu. 2, 3, 4
3290x7c 0x43 0x20 0x17
330
331# CHECK: maddhd 2, 3, 4, 5
3320x10 0x43 0x21 0x70
333
334# CHECK: maddhdu 2, 3, 4, 5
3350x10 0x43 0x21 0x71
336
337# CHECK: maddld 2, 3, 4, 5
3380x10 0x43 0x21 0x73
339
340# CHECK: setb 2, 3
3410x7c 0x4c 0x01 0x00
342
343# CHECK: darn 2, 3
3440x7c 0x43 0x05 0xe6
345
346# CHECK: addpcis 3, 22627
3470x4c,0x71,0x58,0x45
348
349# CHECK: lnia 3
3500x4c,0x60,0x00,0x04
351
352# CHECK: divw 2, 3, 4
3530x7c 0x43 0x23 0xd6
354
355# CHECK: divw. 2, 3, 4
3560x7c 0x43 0x23 0xd7
357
358# CHECK: divwu 2, 3, 4
3590x7c 0x43 0x23 0x96
360
361# CHECK: divwu. 2, 3, 4
3620x7c 0x43 0x23 0x97
363
364# CHECK: divwe 2, 3, 4
3650x7c 0x43 0x23 0x56
366
367# CHECK: divwe. 2, 3, 4
3680x7c 0x43 0x23 0x57
369
370# CHECK: divweu 2, 3, 4
3710x7c 0x43 0x23 0x16
372
373# CHECK: divweu. 2, 3, 4
3740x7c 0x43 0x23 0x17
375
376# CHECK: modsw 2, 3, 4
3770x7c 0x43 0x26 0x16
378
379# CHECK: moduw 2, 3, 4
3800x7c 0x43 0x22 0x16
381
382# CHECK: modsd 2, 3, 4
3830x7c 0x43 0x26 0x12
384
385# CHECK: modud 2, 3, 4
3860x7c 0x43 0x22 0x12
387
388# CHECK: mulld 2, 3, 4
3890x7c 0x43 0x21 0xd2
390
391# CHECK: mulld. 2, 3, 4
3920x7c 0x43 0x21 0xd3
393
394# CHECK: mulhd 2, 3, 4
3950x7c 0x43 0x20 0x92
396
397# CHECK: mulhd. 2, 3, 4
3980x7c 0x43 0x20 0x93
399
400# CHECK: mulhdu 2, 3, 4
4010x7c 0x43 0x20 0x12
402
403# CHECK: mulhdu. 2, 3, 4
4040x7c 0x43 0x20 0x13
405
406# CHECK: divd 2, 3, 4
4070x7c 0x43 0x23 0xd2
408
409# CHECK: divd. 2, 3, 4
4100x7c 0x43 0x23 0xd3
411
412# CHECK: divdu 2, 3, 4
4130x7c 0x43 0x23 0x92
414
415# CHECK: divdu. 2, 3, 4
4160x7c 0x43 0x23 0x93
417
418# CHECK: divde 2, 3, 4
4190x7c 0x43 0x23 0x52
420
421# CHECK: divde. 2, 3, 4
4220x7c 0x43 0x23 0x53
423
424# CHECK: divdeu 2, 3, 4
4250x7c 0x43 0x23 0x12
426
427# CHECK: divdeu. 2, 3, 4
4280x7c 0x43 0x23 0x13
429
430# CHECK: cmpdi 2, 3, 128
4310x2d 0x23 0x00 0x80
432
433# CHECK: cmpd 2, 3, 4
4340x7d 0x23 0x20 0x00
435
436# CHECK: cmpldi 2, 3, 128
4370x29 0x23 0x00 0x80
438
439# CHECK: cmpld 2, 3, 4
4400x7d 0x23 0x20 0x40
441
442# CHECK: cmpwi 2, 3, 128
4430x2d 0x03 0x00 0x80
444
445# CHECK: cmpw 2, 3, 4
4460x7d 0x03 0x20 0x00
447
448# CHECK: cmplwi 2, 3, 128
4490x29 0x03 0x00 0x80
450
451# CHECK: cmplw 2, 3, 4
4520x7d 0x03 0x20 0x40
453
454# CHECK: cmprb 3, 1, 7, 17
4550x7d 0xa7 0x89 0x80
456
457# CHECK: cmpeqb 3, 7, 17
4580x7d 0x87 0x89 0xc0
459
460# CHECK: cnttzw 7, 17
4610x7e 0x27 0x04 0x34
462
463# CHECK: cnttzw. 7, 17
4640x7e 0x27 0x04 0x35
465
466# CHECK: cnttzd 7, 17
4670x7e 0x27 0x04 0x74
468
469# CHECK: cnttzd. 7, 17
4700x7e 0x27 0x04 0x75
471
472# CHECK: twllti 3, 4
4730x0c 0x43 0x00 0x04
474
475# CHECK: twllt 3, 4
4760x7c 0x43 0x20 0x08
477
478# CHECK: tdllti 3, 4
4790x08 0x43 0x00 0x04
480
481# CHECK: tdllt 3, 4
4820x7c 0x43 0x20 0x88
483
484# CHECK: isel 2, 3, 4, 5
4850x7c 0x43 0x21 0x5e
486
487# CHECK: andi. 2, 3, 128
4880x70 0x62 0x00 0x80
489
490# CHECK: andis. 2, 3, 128
4910x74 0x62 0x00 0x80
492
493# CHECK: ori 2, 3, 128
4940x60 0x62 0x00 0x80
495
496# CHECK: oris 2, 3, 128
4970x64 0x62 0x00 0x80
498
499# CHECK: xori 2, 3, 128
5000x68 0x62 0x00 0x80
501
502# CHECK: xoris 2, 3, 128
5030x6c 0x62 0x00 0x80
504
505# CHECK: and 2, 3, 4
5060x7c 0x62 0x20 0x38
507
508# CHECK: and. 2, 3, 4
5090x7c 0x62 0x20 0x39
510
511# CHECK: xor 2, 3, 4
5120x7c 0x62 0x22 0x78
513
514# CHECK: xor. 2, 3, 4
5150x7c 0x62 0x22 0x79
516
517# CHECK: nand 2, 3, 4
5180x7c 0x62 0x23 0xb8
519
520# CHECK: nand. 2, 3, 4
5210x7c 0x62 0x23 0xb9
522
523# CHECK: or 2, 3, 4
5240x7c 0x62 0x23 0x78
525
526# CHECK: or. 2, 3, 4
5270x7c 0x62 0x23 0x79
528
529# CHECK: nor 2, 3, 4
5300x7c 0x62 0x20 0xf8
531
532# CHECK: nor. 2, 3, 4
5330x7c 0x62 0x20 0xf9
534
535# CHECK: eqv 2, 3, 4
5360x7c 0x62 0x22 0x38
537
538# CHECK: eqv. 2, 3, 4
5390x7c 0x62 0x22 0x39
540
541# CHECK: andc 2, 3, 4
5420x7c 0x62 0x20 0x78
543
544# CHECK: andc. 2, 3, 4
5450x7c 0x62 0x20 0x79
546
547# CHECK: orc 2, 3, 4
5480x7c 0x62 0x23 0x38
549
550# CHECK: orc. 2, 3, 4
5510x7c 0x62 0x23 0x39
552
553# CHECK: extsb 2, 3
5540x7c 0x62 0x07 0x74
555
556# CHECK: extsb. 2, 3
5570x7c 0x62 0x07 0x75
558
559# CHECK: extsh 2, 3
5600x7c 0x62 0x07 0x34
561
562# CHECK: extsh. 2, 3
5630x7c 0x62 0x07 0x35
564
565# CHECK: cntlzw 2, 3
5660x7c 0x62 0x00 0x34
567
568# CHECK: cntlzw. 2, 3
5690x7c 0x62 0x00 0x35
570
571# CHECK: popcntw 2, 3
5720x7c 0x62 0x02 0xf4
573
574# CHECK: popcntb 2, 3
5750x7c 0x62 0x00 0xf4
576
577# CHECK: extsw 2, 3
5780x7c 0x62 0x07 0xb4
579
580# CHECK: extsw. 2, 3
5810x7c 0x62 0x07 0xb5
582
583# CHECK: cntlzd 2, 3
5840x7c 0x62 0x00 0x74
585
586# CHECK: cntlzd. 2, 3
5870x7c 0x62 0x00 0x75
588
589# CHECK: popcntd 2, 3
5900x7c 0x62 0x03 0xf4
591
592# CHECK: bpermd 2, 3, 4
5930x7c 0x62 0x21 0xf8
594
595# CHECK: cmpb 7, 21, 4
5960x7e 0xa7 0x23 0xf8
597
598# CHECK: rlwinm 2, 3, 4, 5, 6
5990x54 0x62 0x21 0x4c
600
601# CHECK: rlwinm. 2, 3, 4, 5, 6
6020x54 0x62 0x21 0x4d
603
604# CHECK: rlwnm 2, 3, 4, 5, 6
6050x5c 0x62 0x21 0x4c
606
607# CHECK: rlwnm. 2, 3, 4, 5, 6
6080x5c 0x62 0x21 0x4d
609
610# CHECK: rlwimi 2, 3, 4, 5, 6
6110x50 0x62 0x21 0x4c
612
613# CHECK: rlwimi. 2, 3, 4, 5, 6
6140x50 0x62 0x21 0x4d
615
616# CHECK: rldicl 2, 3, 4, 5
6170x78 0x62 0x21 0x40
618
619# CHECK: rldicl. 2, 3, 4, 5
6200x78 0x62 0x21 0x41
621
622# CHECK: rldicr 2, 3, 4, 5
6230x78 0x62 0x21 0x44
624
625# CHECK: rldicr. 2, 3, 4, 5
6260x78 0x62 0x21 0x45
627
628# CHECK: rldic 2, 3, 4, 5
6290x78 0x62 0x21 0x48
630
631# CHECK: rldic. 2, 3, 4, 5
6320x78 0x62 0x21 0x49
633
634# CHECK: rldcl 2, 3, 4, 5
6350x78 0x62 0x21 0x50
636
637# CHECK: rldcl. 2, 3, 4, 5
6380x78 0x62 0x21 0x51
639
640# CHECK: rldcr 2, 3, 4, 5
6410x78 0x62 0x21 0x52
642
643# CHECK: rldcr. 2, 3, 4, 5
6440x78 0x62 0x21 0x53
645
646# CHECK: rldimi 2, 3, 4, 5
6470x78 0x62 0x21 0x4c
648
649# CHECK: rldimi. 2, 3, 4, 5
6500x78 0x62 0x21 0x4d
651
652# CHECK: slw 2, 3, 4
6530x7c 0x62 0x20 0x30
654
655# CHECK: slw. 2, 3, 4
6560x7c 0x62 0x20 0x31
657
658# CHECK: srw 2, 3, 4
6590x7c 0x62 0x24 0x30
660
661# CHECK: srw. 2, 3, 4
6620x7c 0x62 0x24 0x31
663
664# CHECK: srawi 2, 3, 4
6650x7c 0x62 0x26 0x70
666
667# CHECK: srawi. 2, 3, 4
6680x7c 0x62 0x26 0x71
669
670# CHECK: sraw 2, 3, 4
6710x7c 0x62 0x26 0x30
672
673# CHECK: sraw. 2, 3, 4
6740x7c 0x62 0x26 0x31
675
676# CHECK: sld 2, 3, 4
6770x7c 0x62 0x20 0x36
678
679# CHECK: sld. 2, 3, 4
6800x7c 0x62 0x20 0x37
681
682# CHECK: srd 2, 3, 4
6830x7c 0x62 0x24 0x36
684
685# CHECK: srd. 2, 3, 4
6860x7c 0x62 0x24 0x37
687
688# CHECK: sradi 2, 3, 4
6890x7c 0x62 0x26 0x74
690
691# CHECK: sradi. 2, 3, 4
6920x7c 0x62 0x26 0x75
693
694# CHECK: srad 2, 3, 4
6950x7c 0x62 0x26 0x34
696
697# CHECK: srad. 2, 3, 4
6980x7c 0x62 0x26 0x35
699
700# CHECK: extswsli 2, 3, 4
7010x7c 0x62 0x26 0xf4
702
703# CHECK: extswsli. 2, 3, 4
7040x7c 0x62 0x26 0xf5
705
706# CHECK: mtspr 600, 2
7070x7c 0x58 0x93 0xa6
708
709# CHECK: mfspr 2, 600
7100x7c 0x58 0x92 0xa6
711
712# CHECK: mtcrf 123, 2
7130x7c 0x47 0xb1 0x20
714
715# CHECK: mfcr 2
7160x7c 0x40 0x00 0x26
717
718# CHECK: mtocrf 16, 2
7190x7c 0x51 0x01 0x20
720
721# CHECK: mfocrf 16, 8
7220x7e 0x10 0x80 0x26
723
724# CHECK: mcrxrx 7
7250x7f 0x80 0x04 0x80
726
727# CHECK: mtsrin 10, 12
7280x7d 0x40 0x61 0xe4
729
730# CHECK: mfsrin 10, 12
7310x7d 0x40 0x65 0x26
732
733# CHECK: copy 2, 19, 1
7340x7c 0x22 0x9e 0x0c
735
736# CHECK: paste 17, 1, 1
7370x7c 0x31 0x0f 0x0c
738
739# CHECK: cp_abort
7400x7c 0x00 0x06 0x8c
741
742# CHECK: msgsync
7430x7c 0x00 0x06 0xec
744
745# CHECK: slbieg 6, 21
7460x7c 0xc0 0xab 0xa4
747
748# CHECK: slbsync
7490x7c 0x00 0x02 0xa4
750
751# CHECK: stop
7520x4c 0x00 0x02 0xe4
753