Ulrich Weigand | 640192d | 2013-05-03 19:49:39 +0000 | [diff] [blame] | 1 | |
| 2 | # RUN: llvm-mc -triple powerpc64-unknown-unknown --show-encoding %s | FileCheck %s |
| 3 | |
| 4 | # Branch facility |
| 5 | |
| 6 | # Branch instructions |
| 7 | |
| 8 | # CHECK: b target # encoding: [0b010010AA,A,A,0bAAAAAA00] |
| 9 | # CHECK-NEXT: # fixup A - offset: 0, value: target, kind: fixup_ppc_br24 |
| 10 | b target |
Ulrich Weigand | b6a30d1 | 2013-06-24 11:03:33 +0000 | [diff] [blame] | 11 | # CHECK: ba target # encoding: [0b010010AA,A,A,0bAAAAAA10] |
| 12 | # CHECK-NEXT: # fixup A - offset: 0, value: target, kind: fixup_ppc_br24abs |
| 13 | ba target |
Ulrich Weigand | 640192d | 2013-05-03 19:49:39 +0000 | [diff] [blame] | 14 | # CHECK: bl target # encoding: [0b010010AA,A,A,0bAAAAAA01] |
| 15 | # CHECK-NEXT: # fixup A - offset: 0, value: target, kind: fixup_ppc_br24 |
| 16 | bl target |
Ulrich Weigand | b6a30d1 | 2013-06-24 11:03:33 +0000 | [diff] [blame] | 17 | # CHECK: bla target # encoding: [0b010010AA,A,A,0bAAAAAA11] |
| 18 | # CHECK-NEXT: # fixup A - offset: 0, value: target, kind: fixup_ppc_br24abs |
| 19 | bla target |
Ulrich Weigand | 640192d | 2013-05-03 19:49:39 +0000 | [diff] [blame] | 20 | |
Ulrich Weigand | 824b7d8 | 2013-06-24 11:55:21 +0000 | [diff] [blame^] | 21 | # CHECK: bc 4, 10, target # encoding: [0x40,0x8a,A,0bAAAAAA00] |
| 22 | # CHECK-NEXT: # fixup A - offset: 0, value: target, kind: fixup_ppc_brcond14 |
| 23 | bc 4, 10, target |
| 24 | # CHECK: bca 4, 10, target # encoding: [0x40,0x8a,A,0bAAAAAA10] |
| 25 | # CHECK-NEXT: # fixup A - offset: 0, value: target, kind: fixup_ppc_brcond14abs |
| 26 | bca 4, 10, target |
| 27 | # CHECK: bcl 4, 10, target # encoding: [0x40,0x8a,A,0bAAAAAA01] |
| 28 | # CHECK-NEXT: # fixup A - offset: 0, value: target, kind: fixup_ppc_brcond14 |
| 29 | bcl 4, 10, target |
| 30 | # CHECK: bcla 4, 10, target # encoding: [0x40,0x8a,A,0bAAAAAA11] |
| 31 | # CHECK-NEXT: # fixup A - offset: 0, value: target, kind: fixup_ppc_brcond14abs |
| 32 | bcla 4, 10, target |
Ulrich Weigand | 640192d | 2013-05-03 19:49:39 +0000 | [diff] [blame] | 33 | |
Ulrich Weigand | 824b7d8 | 2013-06-24 11:55:21 +0000 | [diff] [blame^] | 34 | # CHECK: bclr 4, 10, 3 # encoding: [0x4c,0x8a,0x18,0x20] |
| 35 | bclr 4, 10, 3 |
| 36 | # CHECK: bclr 4, 10, 0 # encoding: [0x4c,0x8a,0x00,0x20] |
| 37 | bclr 4, 10 |
| 38 | # CHECK: bclrl 4, 10, 3 # encoding: [0x4c,0x8a,0x18,0x21] |
| 39 | bclrl 4, 10, 3 |
| 40 | # CHECK: bclrl 4, 10, 0 # encoding: [0x4c,0x8a,0x00,0x21] |
| 41 | bclrl 4, 10 |
| 42 | # CHECK: bcctr 4, 10, 3 # encoding: [0x4c,0x8a,0x1c,0x20] |
| 43 | bcctr 4, 10, 3 |
| 44 | # CHECK: bcctr 4, 10, 0 # encoding: [0x4c,0x8a,0x04,0x20] |
| 45 | bcctr 4, 10 |
| 46 | # CHECK: bcctrl 4, 10, 3 # encoding: [0x4c,0x8a,0x1c,0x21] |
| 47 | bcctrl 4, 10, 3 |
| 48 | # CHECK: bcctrl 4, 10, 0 # encoding: [0x4c,0x8a,0x04,0x21] |
| 49 | bcctrl 4, 10 |
Ulrich Weigand | 640192d | 2013-05-03 19:49:39 +0000 | [diff] [blame] | 50 | |
| 51 | # Condition register instructions |
| 52 | |
| 53 | # FIXME: crand 2, 3, 4 |
| 54 | # FIXME: crnand 2, 3, 4 |
| 55 | # CHECK: cror 2, 3, 4 # encoding: [0x4c,0x43,0x23,0x82] |
| 56 | cror 2, 3, 4 |
| 57 | # FIXME: crxor 2, 3, 4 |
| 58 | # FIXME: crnor 2, 3, 4 |
| 59 | # CHECK: creqv 2, 3, 4 # encoding: [0x4c,0x43,0x22,0x42] |
| 60 | creqv 2, 3, 4 |
| 61 | # FIXME: crandc 2, 3, 4 |
| 62 | # FIXME: crorc 2, 3, 4 |
| 63 | # CHECK: mcrf 2, 3 # encoding: [0x4d,0x0c,0x00,0x00] |
| 64 | mcrf 2, 3 |
| 65 | |
| 66 | # System call instruction |
| 67 | |
Bill Schmidt | a87a7e2 | 2013-05-14 19:35:45 +0000 | [diff] [blame] | 68 | # CHECK: sc 1 # encoding: [0x44,0x00,0x00,0x22] |
| 69 | sc 1 |
Ulrich Weigand | 4c44032 | 2013-06-10 17:19:43 +0000 | [diff] [blame] | 70 | # CHECK: sc 0 # encoding: [0x44,0x00,0x00,0x02] |
| 71 | sc |
Ulrich Weigand | 640192d | 2013-05-03 19:49:39 +0000 | [diff] [blame] | 72 | |
| 73 | # Fixed-point facility |
| 74 | |
| 75 | # Fixed-point load instructions |
| 76 | |
| 77 | # CHECK: lbz 2, 128(4) # encoding: [0x88,0x44,0x00,0x80] |
| 78 | lbz 2, 128(4) |
| 79 | # CHECK: lbzx 2, 3, 4 # encoding: [0x7c,0x43,0x20,0xae] |
| 80 | lbzx 2, 3, 4 |
| 81 | # CHECK: lbzu 2, 128(4) # encoding: [0x8c,0x44,0x00,0x80] |
| 82 | lbzu 2, 128(4) |
| 83 | # CHECK: lbzux 2, 3, 4 # encoding: [0x7c,0x43,0x20,0xee] |
| 84 | lbzux 2, 3, 4 |
| 85 | # CHECK: lhz 2, 128(4) # encoding: [0xa0,0x44,0x00,0x80] |
| 86 | lhz 2, 128(4) |
| 87 | # CHECK: lhzx 2, 3, 4 # encoding: [0x7c,0x43,0x22,0x2e] |
| 88 | lhzx 2, 3, 4 |
| 89 | # CHECK: lhzu 2, 128(4) # encoding: [0xa4,0x44,0x00,0x80] |
| 90 | lhzu 2, 128(4) |
| 91 | # CHECK: lhzux 2, 3, 4 # encoding: [0x7c,0x43,0x22,0x6e] |
| 92 | lhzux 2, 3, 4 |
| 93 | # CHECK: lha 2, 128(4) # encoding: [0xa8,0x44,0x00,0x80] |
| 94 | lha 2, 128(4) |
| 95 | # CHECK: lhax 2, 3, 4 # encoding: [0x7c,0x43,0x22,0xae] |
| 96 | lhax 2, 3, 4 |
| 97 | # CHECK: lhau 2, 128(4) # encoding: [0xac,0x44,0x00,0x80] |
| 98 | lhau 2, 128(4) |
| 99 | # CHECK: lhaux 2, 3, 4 # encoding: [0x7c,0x43,0x22,0xee] |
| 100 | lhaux 2, 3, 4 |
| 101 | # CHECK: lwz 2, 128(4) # encoding: [0x80,0x44,0x00,0x80] |
| 102 | lwz 2, 128(4) |
| 103 | # CHECK: lwzx 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x2e] |
| 104 | lwzx 2, 3, 4 |
| 105 | # CHECK: lwzu 2, 128(4) # encoding: [0x84,0x44,0x00,0x80] |
| 106 | lwzu 2, 128(4) |
| 107 | # CHECK: lwzux 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x6e] |
| 108 | lwzux 2, 3, 4 |
| 109 | # CHECK: lwa 2, 128(4) # encoding: [0xe8,0x44,0x00,0x82] |
| 110 | lwa 2, 128(4) |
| 111 | # CHECK: lwax 2, 3, 4 # encoding: [0x7c,0x43,0x22,0xaa] |
| 112 | lwax 2, 3, 4 |
| 113 | # CHECK: lwaux 2, 3, 4 # encoding: [0x7c,0x43,0x22,0xea] |
| 114 | lwaux 2, 3, 4 |
| 115 | # CHECK: ld 2, 128(4) # encoding: [0xe8,0x44,0x00,0x80] |
| 116 | ld 2, 128(4) |
| 117 | # CHECK: ldx 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x2a] |
| 118 | ldx 2, 3, 4 |
| 119 | # CHECK: ldu 2, 128(4) # encoding: [0xe8,0x44,0x00,0x81] |
| 120 | ldu 2, 128(4) |
| 121 | # CHECK: ldux 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x6a] |
| 122 | ldux 2, 3, 4 |
| 123 | |
| 124 | # Fixed-point store instructions |
| 125 | |
| 126 | # CHECK: stb 2, 128(4) # encoding: [0x98,0x44,0x00,0x80] |
| 127 | stb 2, 128(4) |
| 128 | # CHECK: stbx 2, 3, 4 # encoding: [0x7c,0x43,0x21,0xae] |
| 129 | stbx 2, 3, 4 |
| 130 | # CHECK: stbu 2, 128(4) # encoding: [0x9c,0x44,0x00,0x80] |
| 131 | stbu 2, 128(4) |
| 132 | # CHECK: stbux 2, 3, 4 # encoding: [0x7c,0x43,0x21,0xee] |
| 133 | stbux 2, 3, 4 |
| 134 | # CHECK: sth 2, 128(4) # encoding: [0xb0,0x44,0x00,0x80] |
| 135 | sth 2, 128(4) |
| 136 | # CHECK: sthx 2, 3, 4 # encoding: [0x7c,0x43,0x23,0x2e] |
| 137 | sthx 2, 3, 4 |
| 138 | # CHECK: sthu 2, 128(4) # encoding: [0xb4,0x44,0x00,0x80] |
| 139 | sthu 2, 128(4) |
| 140 | # CHECK: sthux 2, 3, 4 # encoding: [0x7c,0x43,0x23,0x6e] |
| 141 | sthux 2, 3, 4 |
| 142 | # CHECK: stw 2, 128(4) # encoding: [0x90,0x44,0x00,0x80] |
| 143 | stw 2, 128(4) |
| 144 | # CHECK: stwx 2, 3, 4 # encoding: [0x7c,0x43,0x21,0x2e] |
| 145 | stwx 2, 3, 4 |
| 146 | # CHECK: stwu 2, 128(4) # encoding: [0x94,0x44,0x00,0x80] |
| 147 | stwu 2, 128(4) |
| 148 | # CHECK: stwux 2, 3, 4 # encoding: [0x7c,0x43,0x21,0x6e] |
| 149 | stwux 2, 3, 4 |
| 150 | # CHECK: std 2, 128(4) # encoding: [0xf8,0x44,0x00,0x80] |
| 151 | std 2, 128(4) |
| 152 | # CHECK: stdx 2, 3, 4 # encoding: [0x7c,0x43,0x21,0x2a] |
| 153 | stdx 2, 3, 4 |
| 154 | # CHECK: stdu 2, 128(4) # encoding: [0xf8,0x44,0x00,0x81] |
| 155 | stdu 2, 128(4) |
| 156 | # CHECK: stdux 2, 3, 4 # encoding: [0x7c,0x43,0x21,0x6a] |
| 157 | stdux 2, 3, 4 |
| 158 | |
| 159 | # Fixed-point load and store with byte reversal instructions |
| 160 | |
| 161 | # CHECK: lhbrx 2, 3, 4 # encoding: [0x7c,0x43,0x26,0x2c] |
| 162 | lhbrx 2, 3, 4 |
| 163 | # CHECK: sthbrx 2, 3, 4 # encoding: [0x7c,0x43,0x27,0x2c] |
| 164 | sthbrx 2, 3, 4 |
| 165 | # CHECK: lwbrx 2, 3, 4 # encoding: [0x7c,0x43,0x24,0x2c] |
| 166 | lwbrx 2, 3, 4 |
| 167 | # CHECK: stwbrx 2, 3, 4 # encoding: [0x7c,0x43,0x25,0x2c] |
| 168 | stwbrx 2, 3, 4 |
| 169 | # CHECK: ldbrx 2, 3, 4 # encoding: [0x7c,0x43,0x24,0x28] |
| 170 | ldbrx 2, 3, 4 |
| 171 | # CHECK: stdbrx 2, 3, 4 # encoding: [0x7c,0x43,0x25,0x28] |
| 172 | stdbrx 2, 3, 4 |
| 173 | |
| 174 | # FIXME: Fixed-point load and store multiple instructions |
| 175 | |
| 176 | # FIXME: Fixed-point move assist instructions |
| 177 | |
| 178 | # Fixed-point arithmetic instructions |
| 179 | |
| 180 | # CHECK: addi 2, 3, 128 # encoding: [0x38,0x43,0x00,0x80] |
| 181 | addi 2, 3, 128 |
| 182 | # CHECK: addis 2, 3, 128 # encoding: [0x3c,0x43,0x00,0x80] |
| 183 | addis 2, 3, 128 |
| 184 | # CHECK: add 2, 3, 4 # encoding: [0x7c,0x43,0x22,0x14] |
| 185 | add 2, 3, 4 |
| 186 | # CHECK: add. 2, 3, 4 # encoding: [0x7c,0x43,0x22,0x15] |
| 187 | add. 2, 3, 4 |
| 188 | # FIXME: addo 2, 3, 4 |
| 189 | # FIXME: addo. 2, 3, 4 |
| 190 | # CHECK: subf 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x50] |
| 191 | subf 2, 3, 4 |
| 192 | # CHECK: subf. 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x51] |
| 193 | subf. 2, 3, 4 |
| 194 | # FIXME: subfo 2, 3, 4 |
| 195 | # FIXME: subfo. 2, 3, 4 |
| 196 | # CHECK: addic 2, 3, 128 # encoding: [0x30,0x43,0x00,0x80] |
| 197 | addic 2, 3, 128 |
| 198 | # CHECK: addic. 2, 3, 128 # encoding: [0x34,0x43,0x00,0x80] |
| 199 | addic. 2, 3, 128 |
| 200 | # CHECK: subfic 2, 3, 4 # encoding: [0x20,0x43,0x00,0x04] |
| 201 | subfic 2, 3, 4 |
| 202 | |
| 203 | # CHECK: addc 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x14] |
| 204 | addc 2, 3, 4 |
| 205 | # CHECK: addc. 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x15] |
| 206 | addc. 2, 3, 4 |
| 207 | # FIXME: addco 2, 3, 4 |
| 208 | # FIXME: addco. 2, 3, 4 |
| 209 | # CHECK: subfc 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x10] |
| 210 | subfc 2, 3, 4 |
| 211 | # CHECK: subfc 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x10] |
| 212 | subfc 2, 3, 4 |
| 213 | # FIXME: subfco 2, 3, 4 |
| 214 | # FIXME: subfco. 2, 3, 4 |
| 215 | |
| 216 | # CHECK: adde 2, 3, 4 # encoding: [0x7c,0x43,0x21,0x14] |
| 217 | adde 2, 3, 4 |
| 218 | # CHECK: adde. 2, 3, 4 # encoding: [0x7c,0x43,0x21,0x15] |
| 219 | adde. 2, 3, 4 |
| 220 | # FIXME: addeo 2, 3, 4 |
| 221 | # FIXME: addeo. 2, 3, 4 |
| 222 | # CHECK: subfe 2, 3, 4 # encoding: [0x7c,0x43,0x21,0x10] |
| 223 | subfe 2, 3, 4 |
| 224 | # CHECK: subfe. 2, 3, 4 # encoding: [0x7c,0x43,0x21,0x11] |
| 225 | subfe. 2, 3, 4 |
| 226 | # FIXME: subfeo 2, 3, 4 |
| 227 | # FIXME: subfeo. 2, 3, 4 |
| 228 | |
| 229 | # CHECK: addme 2, 3 # encoding: [0x7c,0x43,0x01,0xd4] |
| 230 | addme 2, 3 |
| 231 | # CHECK: addme. 2, 3 # encoding: [0x7c,0x43,0x01,0xd5] |
| 232 | addme. 2, 3 |
| 233 | # FIXME: addmeo 2, 3 |
| 234 | # FIXME: addmeo. 2, 3 |
| 235 | # CHECK: subfme 2, 3 # encoding: [0x7c,0x43,0x01,0xd0] |
| 236 | subfme 2, 3 |
| 237 | # CHECK: subfme. 2, 3 # encoding: [0x7c,0x43,0x01,0xd1] |
| 238 | subfme. 2, 3 |
| 239 | # FIXME: subfmeo 2, 3 |
| 240 | # FIXME: subfmeo. 2, 3 |
| 241 | |
| 242 | # CHECK: addze 2, 3 # encoding: [0x7c,0x43,0x01,0x94] |
| 243 | addze 2, 3 |
| 244 | # CHECK: addze. 2, 3 # encoding: [0x7c,0x43,0x01,0x95] |
| 245 | addze. 2, 3 |
| 246 | # FIXME: addzeo 2, 3 |
| 247 | # FIXME: addzeo. 2, 3 |
| 248 | # CHECK: subfze 2, 3 # encoding: [0x7c,0x43,0x01,0x90] |
| 249 | subfze 2, 3 |
| 250 | # CHECK: subfze. 2, 3 # encoding: [0x7c,0x43,0x01,0x91] |
| 251 | subfze. 2, 3 |
| 252 | # FIXME: subfzeo 2, 3 |
| 253 | # FIXME: subfzeo. 2, 3 |
| 254 | |
| 255 | # CHECK: neg 2, 3 # encoding: [0x7c,0x43,0x00,0xd0] |
| 256 | neg 2, 3 |
| 257 | # CHECK: neg. 2, 3 # encoding: [0x7c,0x43,0x00,0xd1] |
| 258 | neg. 2, 3 |
| 259 | # FIXME: nego 2, 3 |
| 260 | # FIXME: nego. 2, 3 |
| 261 | |
| 262 | # CHECK: mulli 2, 3, 128 # encoding: [0x1c,0x43,0x00,0x80] |
| 263 | mulli 2, 3, 128 |
| 264 | # CHECK: mulhw 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x96] |
| 265 | mulhw 2, 3, 4 |
| 266 | # CHECK: mulhw. 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x97] |
| 267 | mulhw. 2, 3, 4 |
| 268 | # CHECK: mullw 2, 3, 4 # encoding: [0x7c,0x43,0x21,0xd6] |
| 269 | mullw 2, 3, 4 |
| 270 | # CHECK: mullw. 2, 3, 4 # encoding: [0x7c,0x43,0x21,0xd7] |
| 271 | mullw. 2, 3, 4 |
| 272 | # FIXME: mullwo 2, 3, 4 |
| 273 | # FIXME: mullwo. 2, 3, 4 |
| 274 | # CHECK: mulhwu 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x16] |
| 275 | mulhwu 2, 3, 4 |
| 276 | # CHECK: mulhwu. 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x17] |
| 277 | mulhwu. 2, 3, 4 |
| 278 | |
| 279 | # CHECK: divw 2, 3, 4 # encoding: [0x7c,0x43,0x23,0xd6] |
| 280 | divw 2, 3, 4 |
| 281 | # CHECK: divw. 2, 3, 4 # encoding: [0x7c,0x43,0x23,0xd7] |
| 282 | divw. 2, 3, 4 |
| 283 | # FIXME: divwo 2, 3, 4 |
| 284 | # FIXME: divwo. 2, 3, 4 |
| 285 | # CHECK: divwu 2, 3, 4 # encoding: [0x7c,0x43,0x23,0x96] |
| 286 | divwu 2, 3, 4 |
| 287 | # CHECK: divwu. 2, 3, 4 # encoding: [0x7c,0x43,0x23,0x97] |
| 288 | divwu. 2, 3, 4 |
| 289 | # FIXME: divwuo 2, 3, 4 |
| 290 | # FIXME: divwuo. 2, 3, 4 |
| 291 | # FIXME: divwe 2, 3, 4 |
| 292 | # FIXME: divwe. 2, 3, 4 |
| 293 | # FIXME: divweo 2, 3, 4 |
| 294 | # FIXME: divweo. 2, 3, 4 |
| 295 | # FIXME: divweu 2, 3, 4 |
| 296 | # FIXME: divweu. 2, 3, 4 |
| 297 | # FIXME: divweuo 2, 3, 4 |
| 298 | # FIXME: divweuo. 2, 3, 4 |
| 299 | |
| 300 | # CHECK: mulld 2, 3, 4 # encoding: [0x7c,0x43,0x21,0xd2] |
| 301 | mulld 2, 3, 4 |
| 302 | # CHECK: mulld. 2, 3, 4 # encoding: [0x7c,0x43,0x21,0xd3] |
| 303 | mulld. 2, 3, 4 |
| 304 | # FIXME: mulldo 2, 3, 4 |
| 305 | # FIXME: mulldo. 2, 3, 4 |
| 306 | # CHECK: mulhd 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x92] |
| 307 | mulhd 2, 3, 4 |
| 308 | # CHECK: mulhd. 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x93] |
| 309 | mulhd. 2, 3, 4 |
| 310 | # CHECK: mulhdu 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x12] |
| 311 | mulhdu 2, 3, 4 |
| 312 | # CHECK: mulhdu. 2, 3, 4 # encoding: [0x7c,0x43,0x20,0x13] |
| 313 | mulhdu. 2, 3, 4 |
| 314 | |
| 315 | # CHECK: divd 2, 3, 4 # encoding: [0x7c,0x43,0x23,0xd2] |
| 316 | divd 2, 3, 4 |
| 317 | # CHECK: divd. 2, 3, 4 # encoding: [0x7c,0x43,0x23,0xd3] |
| 318 | divd. 2, 3, 4 |
| 319 | # FIXME: divdo 2, 3, 4 |
| 320 | # FIXME: divdo. 2, 3, 4 |
| 321 | # CHECK: divdu 2, 3, 4 # encoding: [0x7c,0x43,0x23,0x92] |
| 322 | divdu 2, 3, 4 |
| 323 | # CHECK: divdu. 2, 3, 4 # encoding: [0x7c,0x43,0x23,0x93] |
| 324 | divdu. 2, 3, 4 |
| 325 | # FIXME: divduo 2, 3, 4 |
| 326 | # FIXME: divduo. 2, 3, 4 |
| 327 | # FIXME: divde 2, 3, 4 |
| 328 | # FIXME: divde. 2, 3, 4 |
| 329 | # FIXME: divdeo 2, 3, 4 |
| 330 | # FIXME: divdeo. 2, 3, 4 |
| 331 | # FIXME: divdeu 2, 3, 4 |
| 332 | # FIXME: divdeu. 2, 3, 4 |
| 333 | # FIXME: divdeuo 2, 3, 4 |
| 334 | # FIXME: divdeuo. 2, 3, 4 |
| 335 | |
| 336 | # FIXME: Fixed-point compare instructions |
| 337 | |
| 338 | # FIXME: Fixed-point trap instructions |
| 339 | |
| 340 | # Fixed-point select |
| 341 | |
| 342 | # CHECK: isel 2, 3, 4, 5 # encoding: [0x7c,0x43,0x21,0x5e] |
| 343 | isel 2, 3, 4, 5 |
| 344 | |
| 345 | # Fixed-point logical instructions |
| 346 | |
| 347 | # CHECK: andi. 2, 3, 128 # encoding: [0x70,0x62,0x00,0x80] |
| 348 | andi. 2, 3, 128 |
| 349 | # CHECK: andis. 2, 3, 128 # encoding: [0x74,0x62,0x00,0x80] |
| 350 | andis. 2, 3, 128 |
| 351 | # CHECK: ori 2, 3, 128 # encoding: [0x60,0x62,0x00,0x80] |
| 352 | ori 2, 3, 128 |
| 353 | # CHECK: oris 2, 3, 128 # encoding: [0x64,0x62,0x00,0x80] |
| 354 | oris 2, 3, 128 |
| 355 | # CHECK: xori 2, 3, 128 # encoding: [0x68,0x62,0x00,0x80] |
| 356 | xori 2, 3, 128 |
| 357 | # CHECK: xoris 2, 3, 128 # encoding: [0x6c,0x62,0x00,0x80] |
| 358 | xoris 2, 3, 128 |
| 359 | # CHECK: and 2, 3, 4 # encoding: [0x7c,0x62,0x20,0x38] |
| 360 | and 2, 3, 4 |
| 361 | # CHECK: and. 2, 3, 4 # encoding: [0x7c,0x62,0x20,0x39] |
| 362 | and. 2, 3, 4 |
| 363 | # CHECK: xor 2, 3, 4 # encoding: [0x7c,0x62,0x22,0x78] |
| 364 | xor 2, 3, 4 |
| 365 | # CHECK: xor. 2, 3, 4 # encoding: [0x7c,0x62,0x22,0x79] |
| 366 | xor. 2, 3, 4 |
| 367 | # CHECK: nand 2, 3, 4 # encoding: [0x7c,0x62,0x23,0xb8] |
| 368 | nand 2, 3, 4 |
| 369 | # CHECK: nand. 2, 3, 4 # encoding: [0x7c,0x62,0x23,0xb9] |
| 370 | nand. 2, 3, 4 |
| 371 | # CHECK: or 2, 3, 4 # encoding: [0x7c,0x62,0x23,0x78] |
| 372 | or 2, 3, 4 |
| 373 | # CHECK: or. 2, 3, 4 # encoding: [0x7c,0x62,0x23,0x79] |
| 374 | or. 2, 3, 4 |
| 375 | # CHECK: nor 2, 3, 4 # encoding: [0x7c,0x62,0x20,0xf8] |
| 376 | nor 2, 3, 4 |
| 377 | # CHECK: nor. 2, 3, 4 # encoding: [0x7c,0x62,0x20,0xf9] |
| 378 | nor. 2, 3, 4 |
| 379 | # CHECK: eqv 2, 3, 4 # encoding: [0x7c,0x62,0x22,0x38] |
| 380 | eqv 2, 3, 4 |
| 381 | # CHECK: eqv. 2, 3, 4 # encoding: [0x7c,0x62,0x22,0x39] |
| 382 | eqv. 2, 3, 4 |
| 383 | # CHECK: andc 2, 3, 4 # encoding: [0x7c,0x62,0x20,0x78] |
| 384 | andc 2, 3, 4 |
| 385 | # CHECK: andc. 2, 3, 4 # encoding: [0x7c,0x62,0x20,0x79] |
| 386 | andc. 2, 3, 4 |
| 387 | # CHECK: orc 2, 3, 4 # encoding: [0x7c,0x62,0x23,0x38] |
| 388 | orc 2, 3, 4 |
| 389 | # CHECK: orc. 2, 3, 4 # encoding: [0x7c,0x62,0x23,0x39] |
| 390 | orc. 2, 3, 4 |
| 391 | |
| 392 | # CHECK: extsb 2, 3 # encoding: [0x7c,0x62,0x07,0x74] |
| 393 | extsb 2, 3 |
| 394 | # CHECK: extsb. 2, 3 # encoding: [0x7c,0x62,0x07,0x75] |
| 395 | extsb. 2, 3 |
| 396 | # CHECK: extsh 2, 3 # encoding: [0x7c,0x62,0x07,0x34] |
| 397 | extsh 2, 3 |
| 398 | # CHECK: extsh. 2, 3 # encoding: [0x7c,0x62,0x07,0x35] |
| 399 | extsh. 2, 3 |
| 400 | |
| 401 | # CHECK: cntlzw 2, 3 # encoding: [0x7c,0x62,0x00,0x34] |
| 402 | cntlzw 2, 3 |
| 403 | # CHECK: cntlzw. 2, 3 # encoding: [0x7c,0x62,0x00,0x35] |
| 404 | cntlzw. 2, 3 |
| 405 | # FIXME: cmpb 2, 3, 4 |
| 406 | # FIXME: popcntb 2, 3 |
| 407 | # CHECK: popcntw 2, 3 # encoding: [0x7c,0x62,0x02,0xf4] |
| 408 | popcntw 2, 3 |
| 409 | # FIXME: prtyd 2, 3 |
| 410 | # FIXME: prtyw 2, 3 |
| 411 | |
| 412 | # CHECK: extsw 2, 3 # encoding: [0x7c,0x62,0x07,0xb4] |
| 413 | extsw 2, 3 |
| 414 | # CHECK: extsw. 2, 3 # encoding: [0x7c,0x62,0x07,0xb5] |
| 415 | extsw. 2, 3 |
| 416 | |
| 417 | # CHECK: cntlzd 2, 3 # encoding: [0x7c,0x62,0x00,0x74] |
| 418 | cntlzd 2, 3 |
| 419 | # CHECK: cntlzd. 2, 3 # encoding: [0x7c,0x62,0x00,0x75] |
| 420 | cntlzd. 2, 3 |
| 421 | # CHECK: popcntd 2, 3 # encoding: [0x7c,0x62,0x03,0xf4] |
| 422 | popcntd 2, 3 |
| 423 | # FIXME: bpermd 2, 3, 4 |
| 424 | |
| 425 | # Fixed-point rotate and shift instructions |
| 426 | |
| 427 | # CHECK: rlwinm 2, 3, 4, 5, 6 # encoding: [0x54,0x62,0x21,0x4c] |
| 428 | rlwinm 2, 3, 4, 5, 6 |
| 429 | # CHECK: rlwinm. 2, 3, 4, 5, 6 # encoding: [0x54,0x62,0x21,0x4d] |
| 430 | rlwinm. 2, 3, 4, 5, 6 |
| 431 | # CHECK: rlwnm 2, 3, 4, 5, 6 # encoding: [0x5c,0x62,0x21,0x4c] |
| 432 | rlwnm 2, 3, 4, 5, 6 |
| 433 | # CHECK: rlwnm. 2, 3, 4, 5, 6 # encoding: [0x5c,0x62,0x21,0x4d] |
| 434 | rlwnm. 2, 3, 4, 5, 6 |
| 435 | # CHECK: rlwimi 2, 3, 4, 5, 6 # encoding: [0x50,0x62,0x21,0x4c] |
| 436 | rlwimi 2, 3, 4, 5, 6 |
| 437 | # CHECK: rlwimi. 2, 3, 4, 5, 6 # encoding: [0x50,0x62,0x21,0x4d] |
| 438 | rlwimi. 2, 3, 4, 5, 6 |
| 439 | # CHECK: rldicl 2, 3, 4, 5 # encoding: [0x78,0x62,0x21,0x40] |
| 440 | rldicl 2, 3, 4, 5 |
| 441 | # CHECK: rldicl. 2, 3, 4, 5 # encoding: [0x78,0x62,0x21,0x41] |
| 442 | rldicl. 2, 3, 4, 5 |
| 443 | # CHECK: rldicr 2, 3, 4, 5 # encoding: [0x78,0x62,0x21,0x44] |
| 444 | rldicr 2, 3, 4, 5 |
| 445 | # CHECK: rldicr. 2, 3, 4, 5 # encoding: [0x78,0x62,0x21,0x45] |
| 446 | rldicr. 2, 3, 4, 5 |
| 447 | # FIXME: rldic 2, 3, 4, 5 |
| 448 | # FIXME: rldic. 2, 3, 4, 5 |
| 449 | # CHECK: rldcl 2, 3, 4, 5 # encoding: [0x78,0x62,0x21,0x50] |
| 450 | rldcl 2, 3, 4, 5 |
| 451 | # CHECK: rldcl. 2, 3, 4, 5 # encoding: [0x78,0x62,0x21,0x51] |
| 452 | rldcl. 2, 3, 4, 5 |
| 453 | # FIXME: rldcr 2, 3, 4, 5 |
| 454 | # FIXME: rldcr. 2, 3, 4, 5 |
| 455 | # CHECK: rldimi 2, 3, 4, 5 # encoding: [0x78,0x62,0x21,0x4c] |
| 456 | rldimi 2, 3, 4, 5 |
| 457 | # CHECK: rldimi. 2, 3, 4, 5 # encoding: [0x78,0x62,0x21,0x4d] |
| 458 | rldimi. 2, 3, 4, 5 |
| 459 | |
| 460 | # CHECK: slw 2, 3, 4 # encoding: [0x7c,0x62,0x20,0x30] |
| 461 | slw 2, 3, 4 |
| 462 | # CHECK: slw. 2, 3, 4 # encoding: [0x7c,0x62,0x20,0x31] |
| 463 | slw. 2, 3, 4 |
| 464 | # CHECK: srw 2, 3, 4 # encoding: [0x7c,0x62,0x24,0x30] |
| 465 | srw 2, 3, 4 |
| 466 | # CHECK: srw. 2, 3, 4 # encoding: [0x7c,0x62,0x24,0x31] |
| 467 | srw. 2, 3, 4 |
| 468 | # CHECK: srawi 2, 3, 4 # encoding: [0x7c,0x62,0x26,0x70] |
| 469 | srawi 2, 3, 4 |
| 470 | # CHECK: srawi. 2, 3, 4 # encoding: [0x7c,0x62,0x26,0x71] |
| 471 | srawi. 2, 3, 4 |
| 472 | # CHECK: sraw 2, 3, 4 # encoding: [0x7c,0x62,0x26,0x30] |
| 473 | sraw 2, 3, 4 |
| 474 | # CHECK: sraw. 2, 3, 4 # encoding: [0x7c,0x62,0x26,0x31] |
| 475 | sraw. 2, 3, 4 |
| 476 | # CHECK: sld 2, 3, 4 # encoding: [0x7c,0x62,0x20,0x36] |
| 477 | sld 2, 3, 4 |
| 478 | # CHECK: sld. 2, 3, 4 # encoding: [0x7c,0x62,0x20,0x37] |
| 479 | sld. 2, 3, 4 |
| 480 | # CHECK: srd 2, 3, 4 # encoding: [0x7c,0x62,0x24,0x36] |
| 481 | srd 2, 3, 4 |
| 482 | # CHECK: srd. 2, 3, 4 # encoding: [0x7c,0x62,0x24,0x37] |
| 483 | srd. 2, 3, 4 |
| 484 | # CHECK: sradi 2, 3, 4 # encoding: [0x7c,0x62,0x26,0x74] |
| 485 | sradi 2, 3, 4 |
| 486 | # CHECK: sradi. 2, 3, 4 # encoding: [0x7c,0x62,0x26,0x75] |
| 487 | sradi. 2, 3, 4 |
| 488 | # CHECK: srad 2, 3, 4 # encoding: [0x7c,0x62,0x26,0x34] |
| 489 | srad 2, 3, 4 |
| 490 | # CHECK: srad. 2, 3, 4 # encoding: [0x7c,0x62,0x26,0x35] |
| 491 | srad. 2, 3, 4 |
| 492 | |
| 493 | # FIXME: BCD assist instructions |
| 494 | |
| 495 | # Move to/from system register instructions |
| 496 | |
| 497 | # FIXME: mtspr 256, 2 |
| 498 | # FIXME: mfspr 2, 256 |
| 499 | # CHECK: mtcrf 16, 2 # encoding: [0x7c,0x41,0x01,0x20] |
| 500 | mtcrf 16, 2 |
| 501 | # CHECK: mfcr 2 # encoding: [0x7c,0x40,0x00,0x26] |
| 502 | mfcr 2 |
| 503 | # FIXME: mtocrf 16, 2 |
| 504 | # CHECK: mfocrf 16, 8 # encoding: [0x7e,0x10,0x80,0x26] |
| 505 | mfocrf 16, 8 |
| 506 | # FIXME: mcrxr 2 |
| 507 | |