[InstCombine] Signed saturation patterns
[llvm-core.git] / test / MC / PowerPC / ppc64-encoding-bookIII.s
blob9592f425dce3117d747adb7c5c103ad0e652a73e
1 # RUN: llvm-mc -triple powerpc64-unknown-unknown --show-encoding %s | FileCheck -check-prefix=CHECK-BE %s
2 # RUN: llvm-mc -triple powerpc64le-unknown-unknown --show-encoding %s | FileCheck -check-prefix=CHECK-LE %s
4 # CHECK-BE: hrfid # encoding: [0x4c,0x00,0x02,0x24]
5 # CHECK-LE: hrfid # encoding: [0x24,0x02,0x00,0x4c]
6 hrfid
8 # CHECK-BE: nap # encoding: [0x4c,0x00,0x03,0x64]
9 # CHECK-LE: nap # encoding: [0x64,0x03,0x00,0x4c]
10 nap
12 # CHECK-BE: mtmsr 4 # encoding: [0x7c,0x80,0x01,0x24]
13 # CHECK-LE: mtmsr 4 # encoding: [0x24,0x01,0x80,0x7c]
14 mtmsr %r4
16 # CHECK-BE: mtmsr 4, 1 # encoding: [0x7c,0x81,0x01,0x24]
17 # CHECK-LE: mtmsr 4, 1 # encoding: [0x24,0x01,0x81,0x7c]
18 mtmsr %r4, 1
20 # CHECK-BE: mfmsr 4 # encoding: [0x7c,0x80,0x00,0xa6]
21 # CHECK-LE: mfmsr 4 # encoding: [0xa6,0x00,0x80,0x7c]
22 mfmsr %r4
24 # CHECK-BE: mtmsrd 4 # encoding: [0x7c,0x80,0x01,0x64]
25 # CHECK-LE: mtmsrd 4 # encoding: [0x64,0x01,0x80,0x7c]
26 mtmsrd %r4
28 # CHECK-BE: mtmsrd 4, 1 # encoding: [0x7c,0x81,0x01,0x64]
29 # CHECK-LE: mtmsrd 4, 1 # encoding: [0x64,0x01,0x81,0x7c]
30 mtmsrd %r4, 1
32 # CHECK-BE: mfspr 4, 260 # encoding: [0x7c,0x84,0x42,0xa6]
33 # CHECK-LE: mfspr 4, 260 # encoding: [0xa6,0x42,0x84,0x7c]
34 mfsprg %r4, 4
36 # CHECK-BE: mfspr 4, 261 # encoding: [0x7c,0x85,0x42,0xa6]
37 # CHECK-LE: mfspr 4, 261 # encoding: [0xa6,0x42,0x85,0x7c]
38 mfsprg %r4, 5
40 # CHECK-BE: mfspr 4, 262 # encoding: [0x7c,0x86,0x42,0xa6]
41 # CHECK-LE: mfspr 4, 262 # encoding: [0xa6,0x42,0x86,0x7c]
42 mfsprg %r4, 6
44 # CHECK-BE: mfspr 4, 263 # encoding: [0x7c,0x87,0x42,0xa6]
45 # CHECK-LE: mfspr 4, 263 # encoding: [0xa6,0x42,0x87,0x7c]
46 mfsprg %r4, 7
48 # CHECK-BE: mfspr 2, 260 # encoding: [0x7c,0x44,0x42,0xa6]
49 # CHECK-LE: mfspr 2, 260 # encoding: [0xa6,0x42,0x44,0x7c]
50 mfsprg4 %r2
51 # CHECK-BE: mfspr 2, 261 # encoding: [0x7c,0x45,0x42,0xa6]
52 # CHECK-LE: mfspr 2, 261 # encoding: [0xa6,0x42,0x45,0x7c]
53 mfsprg5 %r2
54 # CHECK-BE: mfspr 2, 262 # encoding: [0x7c,0x46,0x42,0xa6]
55 # CHECK-LE: mfspr 2, 262 # encoding: [0xa6,0x42,0x46,0x7c]
56 mfsprg6 %r2
57 # CHECK-BE: mfspr 2, 263 # encoding: [0x7c,0x47,0x42,0xa6]
58 # CHECK-LE: mfspr 2, 263 # encoding: [0xa6,0x42,0x47,0x7c]
59 mfsprg7 %r2
61 # NOT-CHECK-BE: mtspr 260, 4 # encoding: [0x7c,0x90,0x43,0xa6]
62 # NOT-CHECK-LE: mtspr 260, 4 # encoding: [0xa6,0x43,0x90,0x7c]
63 mtsprg 4, %r4
65 # NOT-CHECK-BE: mtspr 261, 4 # encoding: [0x7c,0x91,0x43,0xa6]
66 # NOT-CHECK-LE: mtspr 261, 4 # encoding: [0xa6,0x43,0x91,0x7c]
67 mtsprg 5, %r4
69 # NOT-CHECK-BE: mtspr 262, 4 # encoding: [0x7c,0x92,0x43,0xa6]
70 # NOT-CHECK-LE: mtspr 262, 4 # encoding: [0xa6,0x43,0x92,0x7c]
71 mtsprg 6, %r4
73 # NOT-CHECK-BE: mtspr 263, 4 # encoding: [0x7c,0x93,0x43,0xa6]
74 # NOT-CHECK-LE: mtspr 263, 4 # encoding: [0xa6,0x43,0x93,0x7c]
75 mtsprg 7, %r4
77 # CHECK-BE: mtspr 260, 4 # encoding: [0x7c,0x84,0x43,0xa6]
78 # CHECK-LE: mtspr 260, 4 # encoding: [0xa6,0x43,0x84,0x7c]
79 mtsprg4 %r4
81 # CHECK-BE: mtspr 261, 4 # encoding: [0x7c,0x85,0x43,0xa6]
82 # CHECK-LE: mtspr 261, 4 # encoding: [0xa6,0x43,0x85,0x7c]
83 mtsprg5 %r4
85 # CHECK-BE: mtspr 262, 4 # encoding: [0x7c,0x86,0x43,0xa6]
86 # CHECK-LE: mtspr 262, 4 # encoding: [0xa6,0x43,0x86,0x7c]
87 mtsprg6 %r4
89 # CHECK-BE: mtspr 263, 4 # encoding: [0x7c,0x87,0x43,0xa6]
90 # CHECK-LE: mtspr 263, 4 # encoding: [0xa6,0x43,0x87,0x7c]
91 mtsprg7 %r4
93 # CHECK-BE: mtspr 280, 4 # encoding: [0x7c,0x98,0x43,0xa6]
94 # CHECK-LE: mtspr 280, 4 # encoding: [0xa6,0x43,0x98,0x7c]
95 mtasr %r4
97 # CHECK-BE: mfspr 4, 22 # encoding: [0x7c,0x96,0x02,0xa6]
98 # CHECK-LE: mfspr 4, 22 # encoding: [0xa6,0x02,0x96,0x7c]
99 mfdec %r4
101 # CHECK-BE: mtspr 22, 4 # encoding: [0x7c,0x96,0x03,0xa6]
102 # CHECK-LE: mtspr 22, 4 # encoding: [0xa6,0x03,0x96,0x7c]
103 mtdec %r4
105 # CHECK-BE: mfpvr 4 # encoding: [0x7c,0x9f,0x42,0xa6]
106 # CHECK-LE: mfpvr 4 # encoding: [0xa6,0x42,0x9f,0x7c]
107 mfpvr %r4
109 # CHECK-BE: mfspr 4, 25 # encoding: [0x7c,0x99,0x02,0xa6]
110 # CHECK-LE: mfspr 4, 25 # encoding: [0xa6,0x02,0x99,0x7c]
111 mfsdr1 %r4
113 # CHECK-BE: mtspr 25, 4 # encoding: [0x7c,0x99,0x03,0xa6]
114 # CHECK-LE: mtspr 25, 4 # encoding: [0xa6,0x03,0x99,0x7c]
115 mtsdr1 %r4
117 # CHECK-BE: mfspr 4, 26 # encoding: [0x7c,0x9a,0x02,0xa6]
118 # CHECK-LE: mfspr 4, 26 # encoding: [0xa6,0x02,0x9a,0x7c]
119 mfsrr0 %r4
121 # CHECK-BE: mtspr 26, 4 # encoding: [0x7c,0x9a,0x03,0xa6]
122 # CHECK-LE: mtspr 26, 4 # encoding: [0xa6,0x03,0x9a,0x7c]
123 mtsrr0 %r4
125 # CHECK-BE: mfspr 4, 27 # encoding: [0x7c,0x9b,0x02,0xa6]
126 # CHECK-LE: mfspr 4, 27 # encoding: [0xa6,0x02,0x9b,0x7c]
127 mfsrr1 %r4
129 # CHECK-BE: mtspr 27, 4 # encoding: [0x7c,0x9b,0x03,0xa6]
130 # CHECK-LE: mtspr 27, 4 # encoding: [0xa6,0x03,0x9b,0x7c]
131 mtsrr1 %r4
133 # CHECK-BE: slbie 4 # encoding: [0x7c,0x00,0x23,0x64]
134 # CHECK-LE: slbie 4 # encoding: [0x64,0x23,0x00,0x7c]
135 slbie %r4
137 # CHECK-BE: slbmte 4, 5 # encoding: [0x7c,0x80,0x2b,0x24]
138 # CHECK-LE: slbmte 4, 5 # encoding: [0x24,0x2b,0x80,0x7c]
139 slbmte %r4, %r5
141 # CHECK-BE: slbmfee 4, 5 # encoding: [0x7c,0x80,0x2f,0x26]
142 # CHECK-LE: slbmfee 4, 5 # encoding: [0x26,0x2f,0x80,0x7c]
143 slbmfee %r4, %r5
145 # CHECK-BE: slbmfev 2, 3 # encoding: [0x7c,0x40,0x1e,0xa6]
146 # CHECK-LE: slbmfev 2, 3 # encoding: [0xa6,0x1e,0x40,0x7c]
147 slbmfev %r2, %r3
149 # CHECK-BE: slbia # encoding: [0x7c,0x00,0x03,0xe4]
150 # CHECK-LE: slbia # encoding: [0xe4,0x03,0x00,0x7c]
151 slbia
153 # CHECK-BE: slbfee. 4, 5 # encoding: [0x7c,0x80,0x2f,0xa7]
154 # CHECK-LE: slbfee. 4, 5 # encoding: [0xa7,0x2f,0x80,0x7c]
155 slbfee. %r4, %r5
157 # CHECK-BE: tlbsync # encoding: [0x7c,0x00,0x04,0x6c]
158 # CHECK-LE: tlbsync # encoding: [0x6c,0x04,0x00,0x7c]
159 tlbsync
161 # CHECK-BE: tlbiel 4 # encoding: [0x7c,0x00,0x22,0x24]
162 # CHECK-LE: tlbiel 4 # encoding: [0x24,0x22,0x00,0x7c]
163 tlbiel %r4
165 # CHECK-BE: tlbie 4 # encoding: [0x7c,0x00,0x22,0x64]
166 # CHECK-LE: tlbie 4 # encoding: [0x64,0x22,0x00,0x7c]
167 tlbie %r4, 0
169 # CHECK-BE: tlbie 4 # encoding: [0x7c,0x00,0x22,0x64]
170 # CHECK-LE: tlbie 4 # encoding: [0x64,0x22,0x00,0x7c]
171 tlbie %r4
173 # CHECK-BE: rfi # encoding: [0x4c,0x00,0x00,0x64]
174 # CHECK-LE: rfi # encoding: [0x64,0x00,0x00,0x4c]
176 # CHECK-BE: rfci # encoding: [0x4c,0x00,0x00,0x66]
177 # CHECK-LE: rfci # encoding: [0x66,0x00,0x00,0x4c]
178 rfci
180 # CHECK-BE: wrtee 12 # encoding: [0x7d,0x80,0x01,0x06]
181 # CHECK-LE: wrtee 12 # encoding: [0x06,0x01,0x80,0x7d]
182 wrtee %r12
184 # CHECK-BE: wrteei 0 # encoding: [0x7c,0x00,0x01,0x46]
185 # CHECK-LE: wrteei 0 # encoding: [0x46,0x01,0x00,0x7c]
186 wrteei 0
188 # CHECK-BE: wrteei 1 # encoding: [0x7c,0x00,0x81,0x46]
189 # CHECK-LE: wrteei 1 # encoding: [0x46,0x81,0x00,0x7c]
190 wrteei 1
192 # CHECK-BE: tlbre # encoding: [0x7c,0x00,0x07,0x64]
193 # CHECK-LE: tlbre # encoding: [0x64,0x07,0x00,0x7c]
194 tlbre
195 # CHECK-BE: tlbwe # encoding: [0x7c,0x00,0x07,0xa4]
196 # CHECK-LE: tlbwe # encoding: [0xa4,0x07,0x00,0x7c]
197 tlbwe
198 # CHECK-BE: tlbivax 11, 12 # encoding: [0x7c,0x0b,0x66,0x24]
199 # CHECK-LE: tlbivax 11, 12 # encoding: [0x24,0x66,0x0b,0x7c]
200 tlbivax %r11, %r12
201 # CHECK-BE: tlbsx 11, 12 # encoding: [0x7c,0x0b,0x67,0x24]
202 # CHECK-LE: tlbsx 11, 12 # encoding: [0x24,0x67,0x0b,0x7c]
203 tlbsx %r11, %r12
205 # CHECK-BE: mfpmr 5, 400 # encoding: [0x7c,0xb0,0x62,0x9c]
206 # CHECK-LE: mfpmr 5, 400 # encoding: [0x9c,0x62,0xb0,0x7c]
207 mfpmr 5, 400
208 # CHECK-BE: mtpmr 400, 6 # encoding: [0x7c,0xd0,0x63,0x9c]
209 # CHECK-LE: mtpmr 400, 6 # encoding: [0x9c,0x63,0xd0,0x7c]
210 mtpmr 400, 6
211 # CHECK-BE: icblc 0, 0, 8 # encoding: [0x7c,0x00,0x41,0xcc]
212 # CHECK-LE: icblc 0, 0, 8 # encoding: [0xcc,0x41,0x00,0x7c]
213 icblc 0, 0, 8
214 # CHECK-BE: icbtls 0, 0, 9 # encoding: [0x7c,0x00,0x4b,0xcc]
215 # CHECK-LE: icbtls 0, 0, 9 # encoding: [0xcc,0x4b,0x00,0x7c]
216 icbtls 0, 0, 9