[AArch64][PATCH 5/14] Support FP16 Scalar Two Register Misc. instructions.
[deliverable/binutils-gdb.git] / opcodes / aarch64-asm-2.c
CommitLineData
a06ea964 1/* This file is automatically generated by aarch64-gen. Do not edit! */
b90efa5b 2/* Copyright (C) 2012-2015 Free Software Foundation, Inc.
a06ea964
NC
3 Contributed by ARM Ltd.
4
5 This file is part of the GNU opcodes library.
6
7 This library is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 3, or (at your option)
10 any later version.
11
12 It is distributed in the hope that it will be useful, but WITHOUT
13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
14 or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
15 License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; see the file COPYING3. If not,
19 see <http://www.gnu.org/licenses/>. */
20
21#include "sysdep.h"
22#include "aarch64-asm.h"
23
24
25const aarch64_opcode *
26aarch64_find_real_opcode (const aarch64_opcode *opcode)
27{
28 /* Use the index as the key to locate the real opcode. */
29 int key = opcode - aarch64_opcode_table;
30 int value;
31 switch (key)
32 {
33 case 3: /* ngc */
35822b38 34 case 2: /* sbc */
a06ea964
NC
35 value = 2; /* --> sbc. */
36 break;
37 case 5: /* ngcs */
35822b38 38 case 4: /* sbcs */
a06ea964
NC
39 value = 4; /* --> sbcs. */
40 break;
41 case 8: /* cmn */
35822b38 42 case 7: /* adds */
a06ea964
NC
43 value = 7; /* --> adds. */
44 break;
45 case 11: /* cmp */
35822b38 46 case 10: /* subs */
a06ea964
NC
47 value = 10; /* --> subs. */
48 break;
49 case 13: /* mov */
35822b38 50 case 12: /* add */
a06ea964
NC
51 value = 12; /* --> add. */
52 break;
53 case 15: /* cmn */
35822b38 54 case 14: /* adds */
a06ea964
NC
55 value = 14; /* --> adds. */
56 break;
57 case 18: /* cmp */
35822b38 58 case 17: /* subs */
a06ea964
NC
59 value = 17; /* --> subs. */
60 break;
61 case 21: /* cmn */
35822b38 62 case 20: /* adds */
a06ea964
NC
63 value = 20; /* --> adds. */
64 break;
65 case 23: /* neg */
35822b38 66 case 22: /* sub */
a06ea964
NC
67 value = 22; /* --> sub. */
68 break;
69 case 26: /* negs */
70 case 25: /* cmp */
35822b38 71 case 24: /* subs */
a06ea964
NC
72 value = 24; /* --> subs. */
73 break;
a06ea964 74 case 141: /* mov */
35822b38 75 case 140: /* umov */
9e1f0fa7 76 value = 140; /* --> umov. */
a06ea964
NC
77 break;
78 case 143: /* mov */
35822b38 79 case 142: /* ins */
a06ea964
NC
80 value = 142; /* --> ins. */
81 break;
9e1f0fa7 82 case 145: /* mov */
35822b38 83 case 144: /* ins */
9e1f0fa7
MW
84 value = 144; /* --> ins. */
85 break;
f3aa142b
MW
86 case 227: /* mvn */
87 case 226: /* not */
88 value = 226; /* --> not. */
89 break;
90 case 302: /* mov */
91 case 301: /* orr */
92 value = 301; /* --> orr. */
93 break;
94 case 371: /* sxtl */
95 case 370: /* sshll */
96 value = 370; /* --> sshll. */
97 break;
98 case 373: /* sxtl2 */
99 case 372: /* sshll2 */
100 value = 372; /* --> sshll2. */
101 break;
102 case 393: /* uxtl */
103 case 392: /* ushll */
104 value = 392; /* --> ushll. */
105 break;
106 case 395: /* uxtl2 */
107 case 394: /* ushll2 */
108 value = 394; /* --> ushll2. */
109 break;
80776b29
MW
110 case 510: /* mov */
111 case 509: /* dup */
112 value = 509; /* --> dup. */
113 break;
114 case 588: /* sxtw */
115 case 587: /* sxth */
116 case 586: /* sxtb */
117 case 589: /* asr */
118 case 585: /* sbfx */
119 case 584: /* sbfiz */
120 case 583: /* sbfm */
121 value = 583; /* --> sbfm. */
122 break;
123 case 592: /* bfc */
124 case 593: /* bfxil */
125 case 591: /* bfi */
126 case 590: /* bfm */
127 value = 590; /* --> bfm. */
128 break;
129 case 598: /* uxth */
130 case 597: /* uxtb */
131 case 600: /* lsr */
132 case 599: /* lsl */
133 case 596: /* ubfx */
134 case 595: /* ubfiz */
135 case 594: /* ubfm */
136 value = 594; /* --> ubfm. */
137 break;
138 case 618: /* cset */
139 case 617: /* cinc */
140 case 616: /* csinc */
141 value = 616; /* --> csinc. */
142 break;
143 case 621: /* csetm */
144 case 620: /* cinv */
145 case 619: /* csinv */
146 value = 619; /* --> csinv. */
147 break;
148 case 623: /* cneg */
149 case 622: /* csneg */
150 value = 622; /* --> csneg. */
151 break;
152 case 641: /* rev */
153 case 642: /* rev64 */
154 value = 641; /* --> rev. */
155 break;
156 case 649: /* lsl */
157 case 648: /* lslv */
158 value = 648; /* --> lslv. */
159 break;
160 case 651: /* lsr */
161 case 650: /* lsrv */
162 value = 650; /* --> lsrv. */
163 break;
164 case 653: /* asr */
165 case 652: /* asrv */
166 value = 652; /* --> asrv. */
167 break;
168 case 655: /* ror */
169 case 654: /* rorv */
170 value = 654; /* --> rorv. */
171 break;
172 case 665: /* mul */
173 case 664: /* madd */
174 value = 664; /* --> madd. */
175 break;
176 case 667: /* mneg */
177 case 666: /* msub */
178 value = 666; /* --> msub. */
179 break;
180 case 669: /* smull */
181 case 668: /* smaddl */
182 value = 668; /* --> smaddl. */
183 break;
184 case 671: /* smnegl */
185 case 670: /* smsubl */
186 value = 670; /* --> smsubl. */
187 break;
188 case 674: /* umull */
189 case 673: /* umaddl */
190 value = 673; /* --> umaddl. */
191 break;
192 case 676: /* umnegl */
193 case 675: /* umsubl */
194 value = 675; /* --> umsubl. */
195 break;
196 case 687: /* ror */
197 case 686: /* extr */
198 value = 686; /* --> extr. */
199 break;
200 case 894: /* bic */
201 case 893: /* and */
202 value = 893; /* --> and. */
203 break;
204 case 896: /* mov */
205 case 895: /* orr */
206 value = 895; /* --> orr. */
207 break;
208 case 899: /* tst */
209 case 898: /* ands */
210 value = 898; /* --> ands. */
211 break;
212 case 904: /* uxtw */
213 case 903: /* mov */
214 case 902: /* orr */
215 value = 902; /* --> orr. */
216 break;
217 case 906: /* mvn */
218 case 905: /* orn */
219 value = 905; /* --> orn. */
220 break;
221 case 910: /* tst */
222 case 909: /* ands */
223 value = 909; /* --> ands. */
224 break;
225 case 1036: /* staddb */
226 case 940: /* ldaddb */
227 value = 940; /* --> ldaddb. */
228 break;
229 case 1037: /* staddh */
230 case 941: /* ldaddh */
231 value = 941; /* --> ldaddh. */
232 break;
233 case 1038: /* stadd */
234 case 942: /* ldadd */
235 value = 942; /* --> ldadd. */
d685192a 236 break;
80776b29
MW
237 case 1039: /* staddlb */
238 case 944: /* ldaddlb */
239 value = 944; /* --> ldaddlb. */
a06ea964 240 break;
80776b29
MW
241 case 1040: /* staddlh */
242 case 947: /* ldaddlh */
243 value = 947; /* --> ldaddlh. */
a06ea964 244 break;
80776b29
MW
245 case 1041: /* staddl */
246 case 950: /* ldaddl */
247 value = 950; /* --> ldaddl. */
a06ea964 248 break;
80776b29
MW
249 case 1042: /* stclrb */
250 case 952: /* ldclrb */
251 value = 952; /* --> ldclrb. */
a06ea964 252 break;
80776b29
MW
253 case 1043: /* stclrh */
254 case 953: /* ldclrh */
255 value = 953; /* --> ldclrh. */
a06ea964 256 break;
80776b29
MW
257 case 1044: /* stclr */
258 case 954: /* ldclr */
259 value = 954; /* --> ldclr. */
a06ea964 260 break;
80776b29
MW
261 case 1045: /* stclrlb */
262 case 956: /* ldclrlb */
263 value = 956; /* --> ldclrlb. */
a06ea964 264 break;
80776b29
MW
265 case 1046: /* stclrlh */
266 case 959: /* ldclrlh */
267 value = 959; /* --> ldclrlh. */
a06ea964 268 break;
80776b29
MW
269 case 1047: /* stclrl */
270 case 962: /* ldclrl */
271 value = 962; /* --> ldclrl. */
e30181a5 272 break;
80776b29
MW
273 case 1048: /* steorb */
274 case 964: /* ldeorb */
275 value = 964; /* --> ldeorb. */
ee804238 276 break;
80776b29
MW
277 case 1049: /* steorh */
278 case 965: /* ldeorh */
279 value = 965; /* --> ldeorh. */
ee804238 280 break;
80776b29
MW
281 case 1050: /* steor */
282 case 966: /* ldeor */
283 value = 966; /* --> ldeor. */
ee804238 284 break;
80776b29
MW
285 case 1051: /* steorlb */
286 case 968: /* ldeorlb */
287 value = 968; /* --> ldeorlb. */
ee804238 288 break;
80776b29
MW
289 case 1052: /* steorlh */
290 case 971: /* ldeorlh */
291 value = 971; /* --> ldeorlh. */
ee804238 292 break;
80776b29
MW
293 case 1053: /* steorl */
294 case 974: /* ldeorl */
295 value = 974; /* --> ldeorl. */
ee804238 296 break;
80776b29
MW
297 case 1054: /* stsetb */
298 case 976: /* ldsetb */
299 value = 976; /* --> ldsetb. */
ee804238 300 break;
80776b29
MW
301 case 1055: /* stseth */
302 case 977: /* ldseth */
303 value = 977; /* --> ldseth. */
ee804238 304 break;
80776b29
MW
305 case 1056: /* stset */
306 case 978: /* ldset */
307 value = 978; /* --> ldset. */
ee804238 308 break;
80776b29
MW
309 case 1057: /* stsetlb */
310 case 980: /* ldsetlb */
311 value = 980; /* --> ldsetlb. */
ee804238 312 break;
80776b29
MW
313 case 1058: /* stsetlh */
314 case 983: /* ldsetlh */
315 value = 983; /* --> ldsetlh. */
ee804238 316 break;
80776b29
MW
317 case 1059: /* stsetl */
318 case 986: /* ldsetl */
319 value = 986; /* --> ldsetl. */
ee804238 320 break;
80776b29
MW
321 case 1060: /* stsmaxb */
322 case 988: /* ldsmaxb */
323 value = 988; /* --> ldsmaxb. */
ee804238 324 break;
80776b29
MW
325 case 1061: /* stsmaxh */
326 case 989: /* ldsmaxh */
327 value = 989; /* --> ldsmaxh. */
ee804238 328 break;
80776b29
MW
329 case 1062: /* stsmax */
330 case 990: /* ldsmax */
331 value = 990; /* --> ldsmax. */
332 break;
333 case 1063: /* stsmaxlb */
334 case 992: /* ldsmaxlb */
335 value = 992; /* --> ldsmaxlb. */
336 break;
337 case 1064: /* stsmaxlh */
338 case 995: /* ldsmaxlh */
339 value = 995; /* --> ldsmaxlh. */
340 break;
341 case 1065: /* stsmaxl */
342 case 998: /* ldsmaxl */
343 value = 998; /* --> ldsmaxl. */
344 break;
345 case 1066: /* stsminb */
346 case 1000: /* ldsminb */
347 value = 1000; /* --> ldsminb. */
348 break;
349 case 1067: /* stsminh */
350 case 1001: /* ldsminh */
351 value = 1001; /* --> ldsminh. */
352 break;
353 case 1068: /* stsmin */
354 case 1002: /* ldsmin */
355 value = 1002; /* --> ldsmin. */
356 break;
357 case 1069: /* stsminlb */
358 case 1004: /* ldsminlb */
359 value = 1004; /* --> ldsminlb. */
360 break;
361 case 1070: /* stsminlh */
362 case 1007: /* ldsminlh */
363 value = 1007; /* --> ldsminlh. */
364 break;
365 case 1071: /* stsminl */
366 case 1010: /* ldsminl */
367 value = 1010; /* --> ldsminl. */
368 break;
369 case 1072: /* stumaxb */
370 case 1012: /* ldumaxb */
371 value = 1012; /* --> ldumaxb. */
372 break;
373 case 1073: /* stumaxh */
374 case 1013: /* ldumaxh */
375 value = 1013; /* --> ldumaxh. */
376 break;
377 case 1074: /* stumax */
378 case 1014: /* ldumax */
379 value = 1014; /* --> ldumax. */
380 break;
381 case 1075: /* stumaxlb */
382 case 1016: /* ldumaxlb */
383 value = 1016; /* --> ldumaxlb. */
384 break;
385 case 1076: /* stumaxlh */
386 case 1019: /* ldumaxlh */
387 value = 1019; /* --> ldumaxlh. */
388 break;
389 case 1077: /* stumaxl */
390 case 1022: /* ldumaxl */
391 value = 1022; /* --> ldumaxl. */
392 break;
393 case 1078: /* stuminb */
394 case 1024: /* lduminb */
395 value = 1024; /* --> lduminb. */
396 break;
397 case 1079: /* stuminh */
398 case 1025: /* lduminh */
399 value = 1025; /* --> lduminh. */
400 break;
401 case 1080: /* stumin */
402 case 1026: /* ldumin */
403 value = 1026; /* --> ldumin. */
404 break;
405 case 1081: /* stuminlb */
406 case 1028: /* lduminlb */
407 value = 1028; /* --> lduminlb. */
408 break;
409 case 1082: /* stuminlh */
410 case 1031: /* lduminlh */
411 value = 1031; /* --> lduminlh. */
412 break;
413 case 1083: /* stuminl */
414 case 1034: /* lduminl */
415 value = 1034; /* --> lduminl. */
416 break;
417 case 1085: /* mov */
418 case 1084: /* movn */
419 value = 1084; /* --> movn. */
420 break;
421 case 1087: /* mov */
422 case 1086: /* movz */
423 value = 1086; /* --> movz. */
424 break;
425 case 1100: /* psb */
426 case 1099: /* esb */
427 case 1098: /* sevl */
428 case 1097: /* sev */
429 case 1096: /* wfi */
430 case 1095: /* wfe */
431 case 1094: /* yield */
432 case 1093: /* nop */
433 case 1092: /* hint */
434 value = 1092; /* --> hint. */
435 break;
436 case 1109: /* tlbi */
437 case 1108: /* ic */
438 case 1107: /* dc */
439 case 1106: /* at */
440 case 1105: /* sys */
441 value = 1105; /* --> sys. */
a06ea964
NC
442 break;
443 default: return NULL;
444 }
445
446 return aarch64_opcode_table + value;
447}
448
449const char*
450aarch64_insert_operand (const aarch64_operand *self,
451 const aarch64_opnd_info *info,
452 aarch64_insn *code, const aarch64_inst *inst)
453{
454 /* Use the index as the key. */
455 int key = self - aarch64_operands;
456 switch (key)
457 {
458 case 1:
459 case 2:
460 case 3:
461 case 4:
462 case 5:
463 case 6:
464 case 7:
465 case 8:
466 case 9:
467 case 10:
a06ea964
NC
468 case 14:
469 case 15:
470 case 16:
ee804238 471 case 17:
a06ea964
NC
472 case 19:
473 case 20:
474 case 21:
475 case 22:
476 case 23:
477 case 24:
478 case 25:
479 case 26:
ee804238 480 case 27:
a06ea964 481 case 35:
ee804238 482 case 36:
a06ea964 483 return aarch64_ins_regno (self, info, code, inst);
a06ea964 484 case 12:
ee804238
JW
485 return aarch64_ins_reg_extended (self, info, code, inst);
486 case 13:
a06ea964 487 return aarch64_ins_reg_shifted (self, info, code, inst);
ee804238 488 case 18:
a06ea964 489 return aarch64_ins_ft (self, info, code, inst);
a06ea964
NC
490 case 28:
491 case 29:
a06ea964 492 case 30:
ee804238 493 return aarch64_ins_reglane (self, info, code, inst);
a06ea964 494 case 31:
ee804238 495 return aarch64_ins_reglist (self, info, code, inst);
a06ea964 496 case 32:
ee804238 497 return aarch64_ins_ldst_reglist (self, info, code, inst);
a06ea964 498 case 33:
ee804238
JW
499 return aarch64_ins_ldst_reglist_r (self, info, code, inst);
500 case 34:
a06ea964 501 return aarch64_ins_ldst_elemlist (self, info, code, inst);
ee804238 502 case 37:
a06ea964
NC
503 case 46:
504 case 47:
505 case 48:
506 case 49:
507 case 50:
508 case 51:
509 case 52:
510 case 53:
511 case 54:
512 case 55:
513 case 56:
514 case 57:
ee804238 515 case 58:
a06ea964
NC
516 case 67:
517 case 68:
68a64283 518 case 69:
ee804238 519 case 70:
a06ea964 520 return aarch64_ins_imm (self, info, code, inst);
a06ea964 521 case 38:
a06ea964 522 case 39:
ee804238 523 return aarch64_ins_advsimd_imm_shift (self, info, code, inst);
a06ea964
NC
524 case 40:
525 case 41:
ee804238 526 case 42:
a06ea964 527 return aarch64_ins_advsimd_imm_modified (self, info, code, inst);
a06ea964 528 case 59:
ee804238 529 return aarch64_ins_limm (self, info, code, inst);
a06ea964 530 case 60:
ee804238 531 return aarch64_ins_aimm (self, info, code, inst);
a06ea964 532 case 61:
ee804238
JW
533 return aarch64_ins_imm_half (self, info, code, inst);
534 case 62:
a06ea964 535 return aarch64_ins_fbits (self, info, code, inst);
68a64283 536 case 64:
ee804238 537 case 65:
a06ea964 538 return aarch64_ins_cond (self, info, code, inst);
a06ea964 539 case 71:
ee804238
JW
540 case 77:
541 return aarch64_ins_addr_simple (self, info, code, inst);
a06ea964 542 case 72:
ee804238 543 return aarch64_ins_addr_regoff (self, info, code, inst);
a06ea964 544 case 73:
a06ea964 545 case 74:
68a64283 546 case 75:
ee804238
JW
547 return aarch64_ins_addr_simm (self, info, code, inst);
548 case 76:
a06ea964 549 return aarch64_ins_addr_uimm12 (self, info, code, inst);
a06ea964 550 case 78:
ee804238 551 return aarch64_ins_simd_addr_post (self, info, code, inst);
a06ea964 552 case 79:
ee804238 553 return aarch64_ins_sysreg (self, info, code, inst);
a06ea964 554 case 80:
ee804238 555 return aarch64_ins_pstatefield (self, info, code, inst);
a06ea964
NC
556 case 81:
557 case 82:
a06ea964
NC
558 case 83:
559 case 84:
ee804238 560 return aarch64_ins_sysins_op (self, info, code, inst);
a06ea964 561 case 85:
68a64283 562 case 86:
ee804238
JW
563 return aarch64_ins_barrier (self, info, code, inst);
564 case 87:
a06ea964 565 return aarch64_ins_prfop (self, info, code, inst);
1e6f4800
MW
566 case 88:
567 return aarch64_ins_hint (self, info, code, inst);
a06ea964
NC
568 default: assert (0); abort ();
569 }
570}
This page took 0.193279 seconds and 4 git commands to generate.