1 /* DO NOT EDIT! -*- buffer-read-only: t -*- vi:set ro: */
2 #line 1 "msp430-decode.opc"
4 /* Copyright (C) 2013-2019 Free Software Foundation, Inc.
5 Contributed by Red Hat.
8 This file is part of the GNU opcodes library.
10 This library is free software; you can redistribute it and/or modify
11 it under the terms of the GNU General Public License as published by
12 the Free Software Foundation; either version 3, or (at your option)
15 It is distributed in the hope that it will be useful, but WITHOUT
16 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
17 or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
18 License for more details.
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
23 MA 02110-1301, USA. */
31 #include "opcode/msp430-decode.h"
37 MSP430_Opcode_Decoded *msp430;
38 int (*getbyte)(void *);
45 #define AU ATTRIBUTE_UNUSED
46 #define GETBYTE() getbyte_swapped (ld)
47 #define B ((unsigned long) GETBYTE ())
50 getbyte_swapped (LocalData *ld)
54 if (ld->op_ptr == ld->msp430->n_bytes)
58 b = ld->getbyte (ld->ptr);
59 ld->op [(ld->msp430->n_bytes++)^1] = b;
61 while (ld->msp430->n_bytes & 1);
63 return ld->op[ld->op_ptr++];
66 #define ID(x) msp430->id = x
68 #define OP(n, t, r, a) (msp430->op[n].type = t, \
69 msp430->op[n].reg = r, \
70 msp430->op[n].addend = a)
72 #define OPX(n, t, r1, r2, a) \
73 (msp430->op[n].type = t, \
74 msp430->op[n].reg = r1, \
75 msp430->op[n].reg2 = r2, \
76 msp430->op[n].addend = a)
78 #define SYNTAX(x) msp430->syntax = x
79 #define UNSUPPORTED() msp430->syntax = "*unknown*"
81 #define DC(c) OP (0, MSP430_Operand_Immediate, 0, c)
82 #define DR(r) OP (0, MSP430_Operand_Register, r, 0)
83 #define DM(r, a) OP (0, MSP430_Operand_Indirect, r, a)
84 #define DA(a) OP (0, MSP430_Operand_Indirect, MSR_None, a)
85 #define AD(r, ad) encode_ad (r, ad, ld, 0)
86 #define ADX(r, ad, x) encode_ad (r, ad, ld, x)
88 #define SC(c) OP (1, MSP430_Operand_Immediate, 0, c)
89 #define SR(r) OP (1, MSP430_Operand_Register, r, 0)
90 #define SM(r, a) OP (1, MSP430_Operand_Indirect, r, a)
91 #define SA(a) OP (1, MSP430_Operand_Indirect, MSR_None, a)
92 #define SI(r) OP (1, MSP430_Operand_Indirect_Postinc, r, 0)
93 #define AS(r, as) encode_as (r, as, ld, 0)
94 #define ASX(r, as, x) encode_as (r, as, ld, x)
96 #define BW(x) msp430->size = (x ? 8 : 16)
97 /* The last 20 is for SWPBX.Z and SXTX.A. */
98 #define ABW(a,x) msp430->size = (a ? ((x ? 8 : 16)) : (x ? 20 : 20))
100 #define IMMU(bytes) immediate (bytes, 0, ld)
101 #define IMMS(bytes) immediate (bytes, 1, ld)
103 /* Helper macros for known status bits settings. */
104 #define F_____ msp430->flags_1 = msp430->flags_0 = 0; msp430->flags_set = 0
105 #define F_VNZC msp430->flags_1 = msp430->flags_0 = 0; msp430->flags_set = 0x87
106 #define F_0NZC msp430->flags_1 = 0; msp430->flags_0 = 0x80; msp430->flags_set = 0x07
109 /* The chip is little-endian, but GETBYTE byte-swaps words because the
110 decoder is based on 16-bit "words" so *this* logic is big-endian. */
113 immediate (int bytes, int sign_extend, LocalData *ld)
121 if (sign_extend && (i & 0x80))
127 if (sign_extend && (i & 0x8000))
134 if (sign_extend && (i & 0x800000))
142 if (sign_extend && (i & 0x80000000ULL))
146 opcodes_error_handler
147 (_("internal error: immediate() called with invalid byte count %d"),
158 01 X(Rn) Sym - X(abs) #1
160 11 (Rn++) #imm - #8 #-1
164 1 X(Rn) Sym - X(abs) - */
167 encode_ad (int reg, int ad, LocalData *ld, int ext)
169 MSP430_Opcode_Decoded *msp430 = ld->msp430;
173 int x = IMMU(2) | (ext << 16);
176 case 0: /* (PC) -> Symbolic. */
177 DA (x + ld->pc + ld->op_ptr - 2);
179 case 2: /* (SR) -> Absolute. */
194 encode_as (int reg, int as, LocalData *ld, int ext)
196 MSP430_Opcode_Decoded *msp430 = ld->msp430;
215 case 0: /* PC -> Symbolic. */
216 x = IMMU(2) | (ext << 16);
217 SA (x + ld->pc + ld->op_ptr - 2);
219 case 2: /* SR -> Absolute. */
220 x = IMMU(2) | (ext << 16);
227 x = IMMU(2) | (ext << 16);
254 /* This fetch *is* the *PC++ that the opcode encodes :-) */
255 x = IMMU(2) | (ext << 16);
274 encode_rep_zc (int srxt, int dsxt, LocalData *ld)
276 MSP430_Opcode_Decoded *msp430 = ld->msp430;
278 msp430->repeat_reg = srxt & 1;
279 msp430->repeats = dsxt;
280 msp430->zc = (srxt & 2) ? 1 : 0;
283 #define REPZC(s,d) encode_rep_zc (s, d, ld)
286 dopc_to_id (int dopc)
290 case 4: return MSO_mov;
291 case 5: return MSO_add;
292 case 6: return MSO_addc;
293 case 7: return MSO_subc;
294 case 8: return MSO_sub;
295 case 9: return MSO_cmp;
296 case 10: return MSO_dadd;
297 case 11: return MSO_bit;
298 case 12: return MSO_bic;
299 case 13: return MSO_bis;
300 case 14: return MSO_xor;
301 case 15: return MSO_and;
302 default: return MSO_unknown;
307 sopc_to_id (int sop, int c)
311 case 0: return MSO_rrc;
312 case 1: return MSO_swpb;
313 case 2: return MSO_rra;
314 case 3: return MSO_sxt;
315 case 4: return MSO_push;
316 case 5: return MSO_call;
317 case 6: return MSO_reti;
318 default: return MSO_unknown;
323 msp430_decode_opcode (unsigned long pc,
324 MSP430_Opcode_Decoded *msp430,
325 int (*getbyte)(void *),
328 LocalData lds, *ld = &lds;
329 unsigned char op_buf[20] = {0};
330 unsigned char *op = op_buf;
333 int srxt_bits, dsxt_bits;
336 lds.getbyte = getbyte;
342 memset (msp430, 0, sizeof (*msp430));
344 /* These are overridden by an extension word. */
352 /* 430X extention word. */
354 switch (op[0] & 0xff)
358 switch (op[1] & 0xf0)
363 /** 0000 srcr 0000 dstr MOVA @%1, %0 */
364 #line 440 "msp430-decode.opc"
365 int srcr AU = op[0] & 0x0f;
366 #line 440 "msp430-decode.opc"
367 int dstr AU = op[1] & 0x0f;
370 printf ("\033[33m%s\033[0m %02x %02x\n",
371 "/** 0000 srcr 0000 dstr MOVA @%1, %0 */",
373 printf (" srcr = 0x%x,", srcr);
374 printf (" dstr = 0x%x\n", dstr);
376 SYNTAX("MOVA @%1, %0");
377 #line 440 "msp430-decode.opc"
378 ID (MSO_mov); SM (srcr, 0); DR (dstr);
380 msp430->ofs_430x = 1;
387 /** 0000 srcr 0001 dstr MOVA @%1+, %0 */
388 #line 445 "msp430-decode.opc"
389 int srcr AU = op[0] & 0x0f;
390 #line 445 "msp430-decode.opc"
391 int dstr AU = op[1] & 0x0f;
394 printf ("\033[33m%s\033[0m %02x %02x\n",
395 "/** 0000 srcr 0001 dstr MOVA @%1+, %0 */",
397 printf (" srcr = 0x%x,", srcr);
398 printf (" dstr = 0x%x\n", dstr);
400 SYNTAX("MOVA @%1+, %0");
401 #line 445 "msp430-decode.opc"
402 ID (MSO_mov); SI (srcr); DR (dstr);
404 msp430->ofs_430x = 1;
411 /** 0000 srcr 0010 dstr MOVA &%1, %0 */
412 #line 450 "msp430-decode.opc"
413 int srcr AU = op[0] & 0x0f;
414 #line 450 "msp430-decode.opc"
415 int dstr AU = op[1] & 0x0f;
418 printf ("\033[33m%s\033[0m %02x %02x\n",
419 "/** 0000 srcr 0010 dstr MOVA &%1, %0 */",
421 printf (" srcr = 0x%x,", srcr);
422 printf (" dstr = 0x%x\n", dstr);
424 SYNTAX("MOVA &%1, %0");
425 #line 450 "msp430-decode.opc"
426 ID (MSO_mov); SA ((srcr << 16) + IMMU(2)); DR (dstr);
428 msp430->ofs_430x = 1;
435 /** 0000 srcr 0011 dstr MOVA %1, %0 */
436 #line 455 "msp430-decode.opc"
437 int srcr AU = op[0] & 0x0f;
438 #line 455 "msp430-decode.opc"
439 int dstr AU = op[1] & 0x0f;
442 printf ("\033[33m%s\033[0m %02x %02x\n",
443 "/** 0000 srcr 0011 dstr MOVA %1, %0 */",
445 printf (" srcr = 0x%x,", srcr);
446 printf (" dstr = 0x%x\n", dstr);
448 SYNTAX("MOVA %1, %0");
449 #line 455 "msp430-decode.opc"
450 ID (MSO_mov); SM (srcr, IMMS(2)); DR (dstr);
452 msp430->ofs_430x = 1;
460 /** 0000 bt00 010w dstr RRCM.A %c, %0 */
461 #line 522 "msp430-decode.opc"
462 int bt AU = (op[0] >> 2) & 0x03;
463 #line 522 "msp430-decode.opc"
464 int w AU = (op[1] >> 4) & 0x01;
465 #line 522 "msp430-decode.opc"
466 int dstr AU = op[1] & 0x0f;
469 printf ("\033[33m%s\033[0m %02x %02x\n",
470 "/** 0000 bt00 010w dstr RRCM.A %c, %0 */",
472 printf (" bt = 0x%x,", bt);
473 printf (" w = 0x%x,", w);
474 printf (" dstr = 0x%x\n", dstr);
476 SYNTAX("RRCM.A %c, %0");
477 #line 522 "msp430-decode.opc"
478 ID (MSO_rrc); DR (dstr); SR (dstr);
479 msp430->repeats = bt;
480 msp430->size = w ? 16 : 20;
481 msp430->ofs_430x = 1;
489 /** 0000 srcr 0110 dstr MOVA %1, &%0 */
490 #line 460 "msp430-decode.opc"
491 int srcr AU = op[0] & 0x0f;
492 #line 460 "msp430-decode.opc"
493 int dstr AU = op[1] & 0x0f;
496 printf ("\033[33m%s\033[0m %02x %02x\n",
497 "/** 0000 srcr 0110 dstr MOVA %1, &%0 */",
499 printf (" srcr = 0x%x,", srcr);
500 printf (" dstr = 0x%x\n", dstr);
502 SYNTAX("MOVA %1, &%0");
503 #line 460 "msp430-decode.opc"
504 ID (MSO_mov); SR (srcr); DA ((dstr << 16) + IMMU(2));
506 msp430->ofs_430x = 1;
513 /** 0000 srcr 0111 dstr MOVA %1, &%0 */
514 #line 465 "msp430-decode.opc"
515 int srcr AU = op[0] & 0x0f;
516 #line 465 "msp430-decode.opc"
517 int dstr AU = op[1] & 0x0f;
520 printf ("\033[33m%s\033[0m %02x %02x\n",
521 "/** 0000 srcr 0111 dstr MOVA %1, &%0 */",
523 printf (" srcr = 0x%x,", srcr);
524 printf (" dstr = 0x%x\n", dstr);
526 SYNTAX("MOVA %1, &%0");
527 #line 465 "msp430-decode.opc"
528 ID (MSO_mov); SR (srcr); DM (dstr, IMMS(2));
530 msp430->ofs_430x = 1;
537 /** 0000 srcr 1000 dstr MOVA %1, %0 */
538 #line 470 "msp430-decode.opc"
539 int srcr AU = op[0] & 0x0f;
540 #line 470 "msp430-decode.opc"
541 int dstr AU = op[1] & 0x0f;
544 printf ("\033[33m%s\033[0m %02x %02x\n",
545 "/** 0000 srcr 1000 dstr MOVA %1, %0 */",
547 printf (" srcr = 0x%x,", srcr);
548 printf (" dstr = 0x%x\n", dstr);
550 SYNTAX("MOVA %1, %0");
551 #line 470 "msp430-decode.opc"
552 ID (MSO_mov); SC ((srcr << 16) + IMMU(2)); DR (dstr);
554 msp430->ofs_430x = 1;
561 /** 0000 srcr 1001 dstr CMPA %1, %0 */
562 #line 475 "msp430-decode.opc"
563 int srcr AU = op[0] & 0x0f;
564 #line 475 "msp430-decode.opc"
565 int dstr AU = op[1] & 0x0f;
568 printf ("\033[33m%s\033[0m %02x %02x\n",
569 "/** 0000 srcr 1001 dstr CMPA %1, %0 */",
571 printf (" srcr = 0x%x,", srcr);
572 printf (" dstr = 0x%x\n", dstr);
574 SYNTAX("CMPA %1, %0");
575 #line 475 "msp430-decode.opc"
576 ID (MSO_cmp); SC ((srcr << 16) + IMMU(2)); DR (dstr);
578 msp430->ofs_430x = 1;
586 /** 0000 srcr 1010 dstr ADDA %1, %0 */
587 #line 481 "msp430-decode.opc"
588 int srcr AU = op[0] & 0x0f;
589 #line 481 "msp430-decode.opc"
590 int dstr AU = op[1] & 0x0f;
593 printf ("\033[33m%s\033[0m %02x %02x\n",
594 "/** 0000 srcr 1010 dstr ADDA %1, %0 */",
596 printf (" srcr = 0x%x,", srcr);
597 printf (" dstr = 0x%x\n", dstr);
599 SYNTAX("ADDA %1, %0");
600 #line 481 "msp430-decode.opc"
601 ID (MSO_add); SC ((srcr << 16) + IMMU(2)); DR (dstr);
603 msp430->ofs_430x = 1;
611 /** 0000 srcr 1011 dstr SUBA %1, %0 */
612 #line 487 "msp430-decode.opc"
613 int srcr AU = op[0] & 0x0f;
614 #line 487 "msp430-decode.opc"
615 int dstr AU = op[1] & 0x0f;
618 printf ("\033[33m%s\033[0m %02x %02x\n",
619 "/** 0000 srcr 1011 dstr SUBA %1, %0 */",
621 printf (" srcr = 0x%x,", srcr);
622 printf (" dstr = 0x%x\n", dstr);
624 SYNTAX("SUBA %1, %0");
625 #line 487 "msp430-decode.opc"
626 ID (MSO_sub); SC ((srcr << 16) + IMMU(2)); DR (dstr);
628 msp430->ofs_430x = 1;
636 /** 0000 srcr 1100 dstr MOVA %1, %0 */
637 #line 499 "msp430-decode.opc"
638 int srcr AU = op[0] & 0x0f;
639 #line 499 "msp430-decode.opc"
640 int dstr AU = op[1] & 0x0f;
643 printf ("\033[33m%s\033[0m %02x %02x\n",
644 "/** 0000 srcr 1100 dstr MOVA %1, %0 */",
646 printf (" srcr = 0x%x,", srcr);
647 printf (" dstr = 0x%x\n", dstr);
649 SYNTAX("MOVA %1, %0");
650 #line 499 "msp430-decode.opc"
651 ID (MSO_mov); SR (srcr); DR (dstr);
653 msp430->ofs_430x = 1;
660 /** 0000 srcr 1101 dstr CMPA %1, %0 */
661 #line 504 "msp430-decode.opc"
662 int srcr AU = op[0] & 0x0f;
663 #line 504 "msp430-decode.opc"
664 int dstr AU = op[1] & 0x0f;
667 printf ("\033[33m%s\033[0m %02x %02x\n",
668 "/** 0000 srcr 1101 dstr CMPA %1, %0 */",
670 printf (" srcr = 0x%x,", srcr);
671 printf (" dstr = 0x%x\n", dstr);
673 SYNTAX("CMPA %1, %0");
674 #line 504 "msp430-decode.opc"
675 ID (MSO_cmp); SR (srcr); DR (dstr);
677 msp430->ofs_430x = 1;
685 /** 0000 srcr 1110 dstr ADDA %1, %0 */
686 #line 510 "msp430-decode.opc"
687 int srcr AU = op[0] & 0x0f;
688 #line 510 "msp430-decode.opc"
689 int dstr AU = op[1] & 0x0f;
692 printf ("\033[33m%s\033[0m %02x %02x\n",
693 "/** 0000 srcr 1110 dstr ADDA %1, %0 */",
695 printf (" srcr = 0x%x,", srcr);
696 printf (" dstr = 0x%x\n", dstr);
698 SYNTAX("ADDA %1, %0");
699 #line 510 "msp430-decode.opc"
700 ID (MSO_add); SR (srcr); DR (dstr);
702 msp430->ofs_430x = 1;
710 /** 0000 srcr 1111 dstr SUBA %1, %0 */
711 #line 516 "msp430-decode.opc"
712 int srcr AU = op[0] & 0x0f;
713 #line 516 "msp430-decode.opc"
714 int dstr AU = op[1] & 0x0f;
717 printf ("\033[33m%s\033[0m %02x %02x\n",
718 "/** 0000 srcr 1111 dstr SUBA %1, %0 */",
720 printf (" srcr = 0x%x,", srcr);
721 printf (" dstr = 0x%x\n", dstr);
723 SYNTAX("SUBA %1, %0");
724 #line 516 "msp430-decode.opc"
725 ID (MSO_sub); SR (srcr); DR (dstr);
727 msp430->ofs_430x = 1;
736 switch (op[1] & 0xf0)
754 /** 0000 bt01 010w dstr RRAM.A %c, %0 */
755 #line 529 "msp430-decode.opc"
756 int bt AU = (op[0] >> 2) & 0x03;
757 #line 529 "msp430-decode.opc"
758 int w AU = (op[1] >> 4) & 0x01;
759 #line 529 "msp430-decode.opc"
760 int dstr AU = op[1] & 0x0f;
763 printf ("\033[33m%s\033[0m %02x %02x\n",
764 "/** 0000 bt01 010w dstr RRAM.A %c, %0 */",
766 printf (" bt = 0x%x,", bt);
767 printf (" w = 0x%x,", w);
768 printf (" dstr = 0x%x\n", dstr);
770 SYNTAX("RRAM.A %c, %0");
771 #line 529 "msp430-decode.opc"
772 ID (MSO_rra); DR (dstr); SR (dstr);
773 msp430->repeats = bt;
774 msp430->size = w ? 16 : 20;
775 msp430->ofs_430x = 1;
793 goto op_semantics_10;
796 goto op_semantics_11;
799 goto op_semantics_12;
802 goto op_semantics_13;
805 goto op_semantics_14;
808 goto op_semantics_15;
814 switch (op[1] & 0xf0)
832 /** 0000 bt10 010w dstr RLAM.A %c, %0 */
833 #line 536 "msp430-decode.opc"
834 int bt AU = (op[0] >> 2) & 0x03;
835 #line 536 "msp430-decode.opc"
836 int w AU = (op[1] >> 4) & 0x01;
837 #line 536 "msp430-decode.opc"
838 int dstr AU = op[1] & 0x0f;
841 printf ("\033[33m%s\033[0m %02x %02x\n",
842 "/** 0000 bt10 010w dstr RLAM.A %c, %0 */",
844 printf (" bt = 0x%x,", bt);
845 printf (" w = 0x%x,", w);
846 printf (" dstr = 0x%x\n", dstr);
848 SYNTAX("RLAM.A %c, %0");
849 #line 536 "msp430-decode.opc"
850 ID (MSO_add); DR (dstr); SR (dstr);
851 msp430->repeats = bt;
852 msp430->size = w ? 16 : 20;
853 msp430->ofs_430x = 1;
871 goto op_semantics_10;
874 goto op_semantics_11;
877 goto op_semantics_12;
880 goto op_semantics_13;
883 goto op_semantics_14;
886 goto op_semantics_15;
892 switch (op[1] & 0xf0)
910 /** 0000 bt11 010w dstr RRUM.A %c, %0 */
911 #line 543 "msp430-decode.opc"
912 int bt AU = (op[0] >> 2) & 0x03;
913 #line 543 "msp430-decode.opc"
914 int w AU = (op[1] >> 4) & 0x01;
915 #line 543 "msp430-decode.opc"
916 int dstr AU = op[1] & 0x0f;
919 printf ("\033[33m%s\033[0m %02x %02x\n",
920 "/** 0000 bt11 010w dstr RRUM.A %c, %0 */",
922 printf (" bt = 0x%x,", bt);
923 printf (" w = 0x%x,", w);
924 printf (" dstr = 0x%x\n", dstr);
926 SYNTAX("RRUM.A %c, %0");
927 #line 543 "msp430-decode.opc"
928 ID (MSO_rru); DR (dstr); SR (dstr);
929 msp430->repeats = bt;
930 msp430->size = w ? 16 : 20;
931 msp430->ofs_430x = 1;
949 goto op_semantics_10;
952 goto op_semantics_11;
955 goto op_semantics_12;
958 goto op_semantics_13;
961 goto op_semantics_14;
964 goto op_semantics_15;
970 switch (op[1] & 0xf0)
1001 goto op_semantics_10;
1004 goto op_semantics_11;
1007 goto op_semantics_12;
1010 goto op_semantics_13;
1013 goto op_semantics_14;
1016 goto op_semantics_15;
1022 switch (op[1] & 0xf0)
1025 goto op_semantics_1;
1028 goto op_semantics_2;
1031 goto op_semantics_3;
1034 goto op_semantics_4;
1038 goto op_semantics_16;
1041 goto op_semantics_6;
1044 goto op_semantics_7;
1047 goto op_semantics_8;
1050 goto op_semantics_9;
1053 goto op_semantics_10;
1056 goto op_semantics_11;
1059 goto op_semantics_12;
1062 goto op_semantics_13;
1065 goto op_semantics_14;
1068 goto op_semantics_15;
1074 switch (op[1] & 0xf0)
1077 goto op_semantics_1;
1080 goto op_semantics_2;
1083 goto op_semantics_3;
1086 goto op_semantics_4;
1090 goto op_semantics_17;
1093 goto op_semantics_6;
1096 goto op_semantics_7;
1099 goto op_semantics_8;
1102 goto op_semantics_9;
1105 goto op_semantics_10;
1108 goto op_semantics_11;
1111 goto op_semantics_12;
1114 goto op_semantics_13;
1117 goto op_semantics_14;
1120 goto op_semantics_15;
1126 switch (op[1] & 0xf0)
1129 goto op_semantics_1;
1132 goto op_semantics_2;
1135 goto op_semantics_3;
1138 goto op_semantics_4;
1142 goto op_semantics_18;
1145 goto op_semantics_6;
1148 goto op_semantics_7;
1151 goto op_semantics_8;
1154 goto op_semantics_9;
1157 goto op_semantics_10;
1160 goto op_semantics_11;
1163 goto op_semantics_12;
1166 goto op_semantics_13;
1169 goto op_semantics_14;
1172 goto op_semantics_15;
1178 switch (op[1] & 0xf0)
1181 goto op_semantics_1;
1184 goto op_semantics_2;
1187 goto op_semantics_3;
1190 goto op_semantics_4;
1194 goto op_semantics_5;
1197 goto op_semantics_6;
1200 goto op_semantics_7;
1203 goto op_semantics_8;
1206 goto op_semantics_9;
1209 goto op_semantics_10;
1212 goto op_semantics_11;
1215 goto op_semantics_12;
1218 goto op_semantics_13;
1221 goto op_semantics_14;
1224 goto op_semantics_15;
1230 switch (op[1] & 0xf0)
1233 goto op_semantics_1;
1236 goto op_semantics_2;
1239 goto op_semantics_3;
1242 goto op_semantics_4;
1246 goto op_semantics_16;
1249 goto op_semantics_6;
1252 goto op_semantics_7;
1255 goto op_semantics_8;
1258 goto op_semantics_9;
1261 goto op_semantics_10;
1264 goto op_semantics_11;
1267 goto op_semantics_12;
1270 goto op_semantics_13;
1273 goto op_semantics_14;
1276 goto op_semantics_15;
1282 switch (op[1] & 0xf0)
1285 goto op_semantics_1;
1288 goto op_semantics_2;
1291 goto op_semantics_3;
1294 goto op_semantics_4;
1298 goto op_semantics_17;
1301 goto op_semantics_6;
1304 goto op_semantics_7;
1307 goto op_semantics_8;
1310 goto op_semantics_9;
1313 goto op_semantics_10;
1316 goto op_semantics_11;
1319 goto op_semantics_12;
1322 goto op_semantics_13;
1325 goto op_semantics_14;
1328 goto op_semantics_15;
1334 switch (op[1] & 0xf0)
1337 goto op_semantics_1;
1340 goto op_semantics_2;
1343 goto op_semantics_3;
1346 goto op_semantics_4;
1350 goto op_semantics_18;
1353 goto op_semantics_6;
1356 goto op_semantics_7;
1359 goto op_semantics_8;
1362 goto op_semantics_9;
1365 goto op_semantics_10;
1368 goto op_semantics_11;
1371 goto op_semantics_12;
1374 goto op_semantics_13;
1377 goto op_semantics_14;
1380 goto op_semantics_15;
1386 switch (op[1] & 0xf0)
1389 goto op_semantics_1;
1392 goto op_semantics_2;
1395 goto op_semantics_3;
1398 goto op_semantics_4;
1402 goto op_semantics_5;
1405 goto op_semantics_6;
1408 goto op_semantics_7;
1411 goto op_semantics_8;
1414 goto op_semantics_9;
1417 goto op_semantics_10;
1420 goto op_semantics_11;
1423 goto op_semantics_12;
1426 goto op_semantics_13;
1429 goto op_semantics_14;
1432 goto op_semantics_15;
1438 switch (op[1] & 0xf0)
1441 goto op_semantics_1;
1444 goto op_semantics_2;
1447 goto op_semantics_3;
1450 goto op_semantics_4;
1454 goto op_semantics_16;
1457 goto op_semantics_6;
1460 goto op_semantics_7;
1463 goto op_semantics_8;
1466 goto op_semantics_9;
1469 goto op_semantics_10;
1472 goto op_semantics_11;
1475 goto op_semantics_12;
1478 goto op_semantics_13;
1481 goto op_semantics_14;
1484 goto op_semantics_15;
1490 switch (op[1] & 0xf0)
1493 goto op_semantics_1;
1496 goto op_semantics_2;
1499 goto op_semantics_3;
1502 goto op_semantics_4;
1506 goto op_semantics_17;
1509 goto op_semantics_6;
1512 goto op_semantics_7;
1515 goto op_semantics_8;
1518 goto op_semantics_9;
1521 goto op_semantics_10;
1524 goto op_semantics_11;
1527 goto op_semantics_12;
1530 goto op_semantics_13;
1533 goto op_semantics_14;
1536 goto op_semantics_15;
1542 switch (op[1] & 0xf0)
1545 goto op_semantics_1;
1548 goto op_semantics_2;
1551 goto op_semantics_3;
1554 goto op_semantics_4;
1558 goto op_semantics_18;
1561 goto op_semantics_6;
1564 goto op_semantics_7;
1567 goto op_semantics_8;
1570 goto op_semantics_9;
1573 goto op_semantics_10;
1576 goto op_semantics_11;
1579 goto op_semantics_12;
1582 goto op_semantics_13;
1585 goto op_semantics_14;
1588 goto op_semantics_15;
1594 switch (op[1] & 0x00)
1599 /** 0001 00so c b ad dreg %S%b %1 */
1600 #line 396 "msp430-decode.opc"
1601 int so AU = op[0] & 0x03;
1602 #line 396 "msp430-decode.opc"
1603 int c AU = (op[1] >> 7) & 0x01;
1604 #line 396 "msp430-decode.opc"
1605 int b AU = (op[1] >> 6) & 0x01;
1606 #line 396 "msp430-decode.opc"
1607 int ad AU = (op[1] >> 4) & 0x03;
1608 #line 396 "msp430-decode.opc"
1609 int dreg AU = op[1] & 0x0f;
1612 printf ("\033[33m%s\033[0m %02x %02x\n",
1613 "/** 0001 00so c b ad dreg %S%b %1 */",
1615 printf (" so = 0x%x,", so);
1616 printf (" c = 0x%x,", c);
1617 printf (" b = 0x%x,", b);
1618 printf (" ad = 0x%x,", ad);
1619 printf (" dreg = 0x%x\n", dreg);
1622 #line 396 "msp430-decode.opc"
1624 ID (sopc_to_id (so,c)); ASX (dreg, ad, srxt_bits); ABW (al_bit, b);
1627 REPZC (srxt_bits, dsxt_bits);
1629 /* The helper functions encode for source, but it's
1630 both source and dest, with a few documented exceptions. */
1631 msp430->op[0] = msp430->op[1];
1633 /* RETI ignores the operand. */
1634 if (msp430->id == MSO_reti)
1635 msp430->syntax = "%S";
1639 case MSO_rrc: F_VNZC; break;
1640 case MSO_swpb: F_____; break;
1641 case MSO_rra: F_0NZC; break;
1642 case MSO_sxt: F_0NZC; break;
1643 case MSO_push: F_____; break;
1644 case MSO_call: F_____; break;
1645 case MSO_reti: F_VNZC; break;
1649 /* 20xx 0010 0000 ---- ----
1650 3cxx 0011 1100 ---- ----
1651 001j mp-- ---- ----. */
1658 switch (op[1] & 0x00)
1661 goto op_semantics_19;
1667 switch (op[1] & 0x00)
1670 goto op_semantics_19;
1676 switch (op[1] & 0xff)
1680 /** 0001 0011 0000 0000 RETI */
1683 printf ("\033[33m%s\033[0m %02x %02x\n",
1684 "/** 0001 0011 0000 0000 RETI */",
1688 #line 550 "msp430-decode.opc"
1691 msp430->ofs_430x = 1;
1838 goto op_semantics_19;
1905 /** 0001 0011 01as dstr CALLA %0 */
1906 #line 555 "msp430-decode.opc"
1907 int as AU = (op[1] >> 4) & 0x03;
1908 #line 555 "msp430-decode.opc"
1909 int dstr AU = op[1] & 0x0f;
1912 printf ("\033[33m%s\033[0m %02x %02x\n",
1913 "/** 0001 0011 01as dstr CALLA %0 */",
1915 printf (" as = 0x%x,", as);
1916 printf (" dstr = 0x%x\n", dstr);
1919 #line 555 "msp430-decode.opc"
1920 ID (MSO_call); AS (dstr, as);
1922 msp430->ofs_430x = 1;
1943 /** 0001 0011 1000 extb CALLA %0 */
1944 #line 560 "msp430-decode.opc"
1945 int extb AU = op[1] & 0x0f;
1948 printf ("\033[33m%s\033[0m %02x %02x\n",
1949 "/** 0001 0011 1000 extb CALLA %0 */",
1951 printf (" extb = 0x%x\n", extb);
1954 #line 560 "msp430-decode.opc"
1955 ID (MSO_call); SA (IMMU(2) | (extb << 16));
1957 msp430->ofs_430x = 1;
1978 /** 0001 0011 1001 extb CALLA %0 */
1979 #line 565 "msp430-decode.opc"
1980 int extb AU = op[1] & 0x0f;
1983 printf ("\033[33m%s\033[0m %02x %02x\n",
1984 "/** 0001 0011 1001 extb CALLA %0 */",
1986 printf (" extb = 0x%x\n", extb);
1989 #line 565 "msp430-decode.opc"
1990 raddr = IMMU(2) | (extb << 16);
1991 if (raddr & 0x80000)
1993 ID (MSO_call); SA (pc + raddr + msp430->n_bytes);
1995 msp430->ofs_430x = 1;
2016 /** 0001 0011 1011 extb CALLA %0 */
2017 #line 573 "msp430-decode.opc"
2018 int extb AU = op[1] & 0x0f;
2021 printf ("\033[33m%s\033[0m %02x %02x\n",
2022 "/** 0001 0011 1011 extb CALLA %0 */",
2024 printf (" extb = 0x%x\n", extb);
2027 #line 573 "msp430-decode.opc"
2028 ID (MSO_call); SC (IMMU(2) | (extb << 16));
2030 msp430->ofs_430x = 1;
2038 switch (op[1] & 0x00)
2043 /** 0001 010w bits srcr PUSHM.A %0 */
2044 #line 578 "msp430-decode.opc"
2045 int w AU = op[0] & 0x01;
2046 #line 578 "msp430-decode.opc"
2047 int bits AU = (op[1] >> 4) & 0x0f;
2048 #line 578 "msp430-decode.opc"
2049 int srcr AU = op[1] & 0x0f;
2052 printf ("\033[33m%s\033[0m %02x %02x\n",
2053 "/** 0001 010w bits srcr PUSHM.A %0 */",
2055 printf (" w = 0x%x,", w);
2056 printf (" bits = 0x%x,", bits);
2057 printf (" srcr = 0x%x\n", srcr);
2059 SYNTAX("PUSHM.A %0");
2060 #line 578 "msp430-decode.opc"
2061 ID (MSO_push); SR (srcr);
2062 msp430->size = w ? 16 : 20;
2063 msp430->repeats = bits;
2064 msp430->ofs_430x = 1;
2072 switch (op[1] & 0x00)
2075 goto op_semantics_20;
2081 switch (op[1] & 0x00)
2086 /** 0001 011w bits dstr POPM.A %0 */
2087 #line 584 "msp430-decode.opc"
2088 int w AU = op[0] & 0x01;
2089 #line 584 "msp430-decode.opc"
2090 int bits AU = (op[1] >> 4) & 0x0f;
2091 #line 584 "msp430-decode.opc"
2092 int dstr AU = op[1] & 0x0f;
2095 printf ("\033[33m%s\033[0m %02x %02x\n",
2096 "/** 0001 011w bits dstr POPM.A %0 */",
2098 printf (" w = 0x%x,", w);
2099 printf (" bits = 0x%x,", bits);
2100 printf (" dstr = 0x%x\n", dstr);
2102 SYNTAX("POPM.A %0");
2103 #line 584 "msp430-decode.opc"
2104 ID (MSO_pop); DR (dstr);
2105 msp430->size = w ? 16 : 20;
2106 msp430->repeats = bits;
2107 msp430->ofs_430x = 1;
2115 switch (op[1] & 0x00)
2118 goto op_semantics_21;
2124 switch (op[1] & 0x30)
2129 /** 0001 1srx t l 00 dsxt 430x */
2130 #line 352 "msp430-decode.opc"
2131 int srx AU = op[0] & 0x07;
2132 #line 352 "msp430-decode.opc"
2133 int t AU = (op[1] >> 7) & 0x01;
2134 #line 352 "msp430-decode.opc"
2135 int l AU = (op[1] >> 6) & 0x01;
2136 #line 352 "msp430-decode.opc"
2137 int dsxt AU = op[1] & 0x0f;
2140 printf ("\033[33m%s\033[0m %02x %02x\n",
2141 "/** 0001 1srx t l 00 dsxt 430x */",
2143 printf (" srx = 0x%x,", srx);
2144 printf (" t = 0x%x,", t);
2145 printf (" l = 0x%x,", l);
2146 printf (" dsxt = 0x%x\n", dsxt);
2149 #line 352 "msp430-decode.opc"
2152 srxt_bits = srx * 2 + t;
2154 op = op_buf + lds.op_ptr;
2155 msp430->ofs_430x = 1;
2156 goto post_extension_word;
2159 opcode:4 sreg:4 Ad:1 BW:1 As:2 Dreg:4
2162 opcode:9 BW:1 Ad:2 DSreg:4
2165 opcode:3 Cond:3 pcrel:10. */
2167 /* Double-Operand "opcode" fields. */
2171 default: UNSUPPORTED(); break;
2176 switch (op[1] & 0x30)
2179 goto op_semantics_22;
2181 default: UNSUPPORTED(); break;
2186 switch (op[1] & 0x30)
2189 goto op_semantics_22;
2191 default: UNSUPPORTED(); break;
2196 switch (op[1] & 0x30)
2199 goto op_semantics_22;
2201 default: UNSUPPORTED(); break;
2206 switch (op[1] & 0x30)
2209 goto op_semantics_22;
2211 default: UNSUPPORTED(); break;
2216 switch (op[1] & 0x30)
2219 goto op_semantics_22;
2221 default: UNSUPPORTED(); break;
2226 switch (op[1] & 0x30)
2229 goto op_semantics_22;
2231 default: UNSUPPORTED(); break;
2236 switch (op[1] & 0x30)
2239 goto op_semantics_22;
2241 default: UNSUPPORTED(); break;
2246 switch (op[1] & 0x00)
2251 /** 001jmp aa addrlsbs %J %1 */
2252 #line 426 "msp430-decode.opc"
2253 int jmp AU = (op[0] >> 2) & 0x07;
2254 #line 426 "msp430-decode.opc"
2255 int aa AU = op[0] & 0x03;
2256 #line 426 "msp430-decode.opc"
2257 int addrlsbs AU = op[1];
2260 printf ("\033[33m%s\033[0m %02x %02x\n",
2261 "/** 001jmp aa addrlsbs %J %1 */",
2263 printf (" jmp = 0x%x,", jmp);
2264 printf (" aa = 0x%x,", aa);
2265 printf (" addrlsbs = 0x%x\n", addrlsbs);
2268 #line 426 "msp430-decode.opc"
2270 raddr = (aa << 9) | (addrlsbs << 1);
2272 raddr = raddr - 0x800;
2273 /* This is a pc-relative jump, but we don't use SM because that
2274 would load the target address from the memory at X(PC), not use
2275 PC+X *as* the address. So we use SC to use the address, not the
2276 data at that address. */
2277 ID (MSO_jmp); SC (pc + raddr + msp430->n_bytes);
2280 /* Extended instructions. */
2288 switch (op[1] & 0x00)
2291 goto op_semantics_23;
2297 switch (op[1] & 0x00)
2300 goto op_semantics_23;
2306 switch (op[1] & 0x00)
2309 goto op_semantics_23;
2315 switch (op[1] & 0x00)
2318 goto op_semantics_23;
2324 switch (op[1] & 0x00)
2327 goto op_semantics_23;
2333 switch (op[1] & 0x00)
2336 goto op_semantics_23;
2342 switch (op[1] & 0x00)
2345 goto op_semantics_23;
2351 switch (op[1] & 0x00)
2354 goto op_semantics_23;
2360 switch (op[1] & 0x00)
2363 goto op_semantics_23;
2369 switch (op[1] & 0x00)
2372 goto op_semantics_23;
2378 switch (op[1] & 0x00)
2381 goto op_semantics_23;
2387 switch (op[1] & 0x00)
2390 goto op_semantics_23;
2396 switch (op[1] & 0x00)
2399 goto op_semantics_23;
2405 switch (op[1] & 0x00)
2408 goto op_semantics_23;
2414 switch (op[1] & 0x00)
2417 goto op_semantics_23;
2423 switch (op[1] & 0x00)
2426 goto op_semantics_23;
2432 switch (op[1] & 0x00)
2435 goto op_semantics_23;
2441 switch (op[1] & 0x00)
2444 goto op_semantics_23;
2450 switch (op[1] & 0x00)
2453 goto op_semantics_23;
2459 switch (op[1] & 0x00)
2462 goto op_semantics_23;
2468 switch (op[1] & 0x00)
2471 goto op_semantics_23;
2477 switch (op[1] & 0x00)
2480 goto op_semantics_23;
2486 switch (op[1] & 0x00)
2489 goto op_semantics_23;
2495 switch (op[1] & 0x00)
2498 goto op_semantics_23;
2504 switch (op[1] & 0x00)
2507 goto op_semantics_23;
2513 switch (op[1] & 0x00)
2516 goto op_semantics_23;
2522 switch (op[1] & 0x00)
2525 goto op_semantics_23;
2531 switch (op[1] & 0x00)
2534 goto op_semantics_23;
2540 switch (op[1] & 0x00)
2543 goto op_semantics_23;
2549 switch (op[1] & 0x00)
2552 goto op_semantics_23;
2558 switch (op[1] & 0x00)
2561 goto op_semantics_23;
2567 switch (op[1] & 0x00)
2572 /** dopc sreg a b as dreg %D%b %1,%0 */
2573 #line 373 "msp430-decode.opc"
2574 int dopc AU = (op[0] >> 4) & 0x0f;
2575 #line 373 "msp430-decode.opc"
2576 int sreg AU = op[0] & 0x0f;
2577 #line 373 "msp430-decode.opc"
2578 int a AU = (op[1] >> 7) & 0x01;
2579 #line 373 "msp430-decode.opc"
2580 int b AU = (op[1] >> 6) & 0x01;
2581 #line 373 "msp430-decode.opc"
2582 int as AU = (op[1] >> 4) & 0x03;
2583 #line 373 "msp430-decode.opc"
2584 int dreg AU = op[1] & 0x0f;
2587 printf ("\033[33m%s\033[0m %02x %02x\n",
2588 "/** dopc sreg a b as dreg %D%b %1,%0 */",
2590 printf (" dopc = 0x%x,", dopc);
2591 printf (" sreg = 0x%x,", sreg);
2592 printf (" a = 0x%x,", a);
2593 printf (" b = 0x%x,", b);
2594 printf (" as = 0x%x,", as);
2595 printf (" dreg = 0x%x\n", dreg);
2597 SYNTAX("%D%b %1,%0");
2598 #line 373 "msp430-decode.opc"
2600 ID (dopc_to_id (dopc)); ASX (sreg, as, srxt_bits); ADX (dreg, a, dsxt_bits); ABW (al_bit, b);
2601 if (a == 0 && as == 0)
2602 REPZC (srxt_bits, dsxt_bits);
2606 case MSO_mov: F_____; break;
2607 case MSO_add: F_VNZC; break;
2608 case MSO_addc: F_VNZC; break;
2609 case MSO_subc: F_VNZC; break;
2610 case MSO_sub: F_VNZC; break;
2611 case MSO_cmp: F_VNZC; break;
2612 case MSO_dadd: F_VNZC; break;
2613 case MSO_bit: F_0NZC; break;
2614 case MSO_bic: F_____; break;
2615 case MSO_bis: F_____; break;
2616 case MSO_xor: F_VNZC; break;
2617 case MSO_and: F_0NZC; break;
2627 switch (op[1] & 0x00)
2630 goto op_semantics_24;
2636 switch (op[1] & 0x00)
2639 goto op_semantics_24;
2645 switch (op[1] & 0x00)
2648 goto op_semantics_24;
2654 switch (op[1] & 0x00)
2657 goto op_semantics_24;
2663 switch (op[1] & 0x00)
2666 goto op_semantics_24;
2672 switch (op[1] & 0x00)
2675 goto op_semantics_24;
2681 switch (op[1] & 0x00)
2684 goto op_semantics_24;
2690 switch (op[1] & 0x00)
2693 goto op_semantics_24;
2699 switch (op[1] & 0x00)
2702 goto op_semantics_24;
2708 switch (op[1] & 0x00)
2711 goto op_semantics_24;
2717 switch (op[1] & 0x00)
2720 goto op_semantics_24;
2726 switch (op[1] & 0x00)
2729 goto op_semantics_24;
2735 switch (op[1] & 0x00)
2738 goto op_semantics_24;
2744 switch (op[1] & 0x00)
2747 goto op_semantics_24;
2753 switch (op[1] & 0x00)
2756 goto op_semantics_24;
2762 switch (op[1] & 0x00)
2765 goto op_semantics_24;
2771 switch (op[1] & 0x00)
2774 goto op_semantics_24;
2780 switch (op[1] & 0x00)
2783 goto op_semantics_24;
2789 switch (op[1] & 0x00)
2792 goto op_semantics_24;
2798 switch (op[1] & 0x00)
2801 goto op_semantics_24;
2807 switch (op[1] & 0x00)
2810 goto op_semantics_24;
2816 switch (op[1] & 0x00)
2819 goto op_semantics_24;
2825 switch (op[1] & 0x00)
2828 goto op_semantics_24;
2834 switch (op[1] & 0x00)
2837 goto op_semantics_24;
2843 switch (op[1] & 0x00)
2846 goto op_semantics_24;
2852 switch (op[1] & 0x00)
2855 goto op_semantics_24;
2861 switch (op[1] & 0x00)
2864 goto op_semantics_24;
2870 switch (op[1] & 0x00)
2873 goto op_semantics_24;
2879 switch (op[1] & 0x00)
2882 goto op_semantics_24;
2888 switch (op[1] & 0x00)
2891 goto op_semantics_24;
2897 switch (op[1] & 0x00)
2900 goto op_semantics_24;
2906 switch (op[1] & 0x00)
2909 goto op_semantics_24;
2915 switch (op[1] & 0x00)
2918 goto op_semantics_24;
2924 switch (op[1] & 0x00)
2927 goto op_semantics_24;
2933 switch (op[1] & 0x00)
2936 goto op_semantics_24;
2942 switch (op[1] & 0x00)
2945 goto op_semantics_24;
2951 switch (op[1] & 0x00)
2954 goto op_semantics_24;
2960 switch (op[1] & 0x00)
2963 goto op_semantics_24;
2969 switch (op[1] & 0x00)
2972 goto op_semantics_24;
2978 switch (op[1] & 0x00)
2981 goto op_semantics_24;
2987 switch (op[1] & 0x00)
2990 goto op_semantics_24;
2996 switch (op[1] & 0x00)
2999 goto op_semantics_24;
3005 switch (op[1] & 0x00)
3008 goto op_semantics_24;
3014 switch (op[1] & 0x00)
3017 goto op_semantics_24;
3023 switch (op[1] & 0x00)
3026 goto op_semantics_24;
3032 switch (op[1] & 0x00)
3035 goto op_semantics_24;
3041 switch (op[1] & 0x00)
3044 goto op_semantics_24;
3050 switch (op[1] & 0x00)
3053 goto op_semantics_24;
3059 switch (op[1] & 0x00)
3062 goto op_semantics_24;
3068 switch (op[1] & 0x00)
3071 goto op_semantics_24;
3077 switch (op[1] & 0x00)
3080 goto op_semantics_24;
3086 switch (op[1] & 0x00)
3089 goto op_semantics_24;
3095 switch (op[1] & 0x00)
3098 goto op_semantics_24;
3104 switch (op[1] & 0x00)
3107 goto op_semantics_24;
3113 switch (op[1] & 0x00)
3116 goto op_semantics_24;
3122 switch (op[1] & 0x00)
3125 goto op_semantics_24;
3131 switch (op[1] & 0x00)
3134 goto op_semantics_24;
3140 switch (op[1] & 0x00)
3143 goto op_semantics_24;
3149 switch (op[1] & 0x00)
3152 goto op_semantics_24;
3158 switch (op[1] & 0x00)
3161 goto op_semantics_24;
3167 switch (op[1] & 0x00)
3170 goto op_semantics_24;
3176 switch (op[1] & 0x00)
3179 goto op_semantics_24;
3185 switch (op[1] & 0x00)
3188 goto op_semantics_24;
3194 switch (op[1] & 0x00)
3197 goto op_semantics_24;
3203 switch (op[1] & 0x00)
3206 goto op_semantics_24;
3212 switch (op[1] & 0x00)
3215 goto op_semantics_24;
3221 switch (op[1] & 0x00)
3224 goto op_semantics_24;
3230 switch (op[1] & 0x00)
3233 goto op_semantics_24;
3239 switch (op[1] & 0x00)
3242 goto op_semantics_24;
3248 switch (op[1] & 0x00)
3251 goto op_semantics_24;
3257 switch (op[1] & 0x00)
3260 goto op_semantics_24;
3266 switch (op[1] & 0x00)
3269 goto op_semantics_24;
3275 switch (op[1] & 0x00)
3278 goto op_semantics_24;
3284 switch (op[1] & 0x00)
3287 goto op_semantics_24;
3293 switch (op[1] & 0x00)
3296 goto op_semantics_24;
3302 switch (op[1] & 0x00)
3305 goto op_semantics_24;
3311 switch (op[1] & 0x00)
3314 goto op_semantics_24;
3320 switch (op[1] & 0x00)
3323 goto op_semantics_24;
3329 switch (op[1] & 0x00)
3332 goto op_semantics_24;
3338 switch (op[1] & 0x00)
3341 goto op_semantics_24;
3347 switch (op[1] & 0x00)
3350 goto op_semantics_24;
3356 switch (op[1] & 0x00)
3359 goto op_semantics_24;
3365 switch (op[1] & 0x00)
3368 goto op_semantics_24;
3374 switch (op[1] & 0x00)
3377 goto op_semantics_24;
3383 switch (op[1] & 0x00)
3386 goto op_semantics_24;
3392 switch (op[1] & 0x00)
3395 goto op_semantics_24;
3401 switch (op[1] & 0x00)
3404 goto op_semantics_24;
3410 switch (op[1] & 0x00)
3413 goto op_semantics_24;
3419 switch (op[1] & 0x00)
3422 goto op_semantics_24;
3428 switch (op[1] & 0x00)
3431 goto op_semantics_24;
3437 switch (op[1] & 0x00)
3440 goto op_semantics_24;
3446 switch (op[1] & 0x00)
3449 goto op_semantics_24;
3455 switch (op[1] & 0x00)
3458 goto op_semantics_24;
3464 switch (op[1] & 0x00)
3467 goto op_semantics_24;
3473 switch (op[1] & 0x00)
3476 goto op_semantics_24;
3482 switch (op[1] & 0x00)
3485 goto op_semantics_24;
3491 switch (op[1] & 0x00)
3494 goto op_semantics_24;
3500 switch (op[1] & 0x00)
3503 goto op_semantics_24;
3509 switch (op[1] & 0x00)
3512 goto op_semantics_24;
3518 switch (op[1] & 0x00)
3521 goto op_semantics_24;
3527 switch (op[1] & 0x00)
3530 goto op_semantics_24;
3536 switch (op[1] & 0x00)
3539 goto op_semantics_24;
3545 switch (op[1] & 0x00)
3548 goto op_semantics_24;
3554 switch (op[1] & 0x00)
3557 goto op_semantics_24;
3563 switch (op[1] & 0x00)
3566 goto op_semantics_24;
3572 switch (op[1] & 0x00)
3575 goto op_semantics_24;
3581 switch (op[1] & 0x00)
3584 goto op_semantics_24;
3590 switch (op[1] & 0x00)
3593 goto op_semantics_24;
3599 switch (op[1] & 0x00)
3602 goto op_semantics_24;
3608 switch (op[1] & 0x00)
3611 goto op_semantics_24;
3617 switch (op[1] & 0x00)
3620 goto op_semantics_24;
3626 switch (op[1] & 0x00)
3629 goto op_semantics_24;
3635 switch (op[1] & 0x00)
3638 goto op_semantics_24;
3644 switch (op[1] & 0x00)
3647 goto op_semantics_24;
3653 switch (op[1] & 0x00)
3656 goto op_semantics_24;
3662 switch (op[1] & 0x00)
3665 goto op_semantics_24;
3671 switch (op[1] & 0x00)
3674 goto op_semantics_24;
3680 switch (op[1] & 0x00)
3683 goto op_semantics_24;
3689 switch (op[1] & 0x00)
3692 goto op_semantics_24;
3698 switch (op[1] & 0x00)
3701 goto op_semantics_24;
3707 switch (op[1] & 0x00)
3710 goto op_semantics_24;
3716 switch (op[1] & 0x00)
3719 goto op_semantics_24;
3725 switch (op[1] & 0x00)
3728 goto op_semantics_24;
3734 switch (op[1] & 0x00)
3737 goto op_semantics_24;
3743 switch (op[1] & 0x00)
3746 goto op_semantics_24;
3752 switch (op[1] & 0x00)
3755 goto op_semantics_24;
3761 switch (op[1] & 0x00)
3764 goto op_semantics_24;
3770 switch (op[1] & 0x00)
3773 goto op_semantics_24;
3779 switch (op[1] & 0x00)
3782 goto op_semantics_24;
3788 switch (op[1] & 0x00)
3791 goto op_semantics_24;
3797 switch (op[1] & 0x00)
3800 goto op_semantics_24;
3806 switch (op[1] & 0x00)
3809 goto op_semantics_24;
3815 switch (op[1] & 0x00)
3818 goto op_semantics_24;
3824 switch (op[1] & 0x00)
3827 goto op_semantics_24;
3833 switch (op[1] & 0x00)
3836 goto op_semantics_24;
3842 switch (op[1] & 0x00)
3845 goto op_semantics_24;
3851 switch (op[1] & 0x00)
3854 goto op_semantics_24;
3860 switch (op[1] & 0x00)
3863 goto op_semantics_24;
3869 switch (op[1] & 0x00)
3872 goto op_semantics_24;
3878 switch (op[1] & 0x00)
3881 goto op_semantics_24;
3887 switch (op[1] & 0x00)
3890 goto op_semantics_24;
3896 switch (op[1] & 0x00)
3899 goto op_semantics_24;
3905 switch (op[1] & 0x00)
3908 goto op_semantics_24;
3914 switch (op[1] & 0x00)
3917 goto op_semantics_24;
3923 switch (op[1] & 0x00)
3926 goto op_semantics_24;
3932 switch (op[1] & 0x00)
3935 goto op_semantics_24;
3941 switch (op[1] & 0x00)
3944 goto op_semantics_24;
3950 switch (op[1] & 0x00)
3953 goto op_semantics_24;
3959 switch (op[1] & 0x00)
3962 goto op_semantics_24;
3968 switch (op[1] & 0x00)
3971 goto op_semantics_24;
3977 switch (op[1] & 0x00)
3980 goto op_semantics_24;
3986 switch (op[1] & 0x00)
3989 goto op_semantics_24;
3995 switch (op[1] & 0x00)
3998 goto op_semantics_24;
4004 switch (op[1] & 0x00)
4007 goto op_semantics_24;
4013 switch (op[1] & 0x00)
4016 goto op_semantics_24;
4022 switch (op[1] & 0x00)
4025 goto op_semantics_24;
4031 switch (op[1] & 0x00)
4034 goto op_semantics_24;
4040 switch (op[1] & 0x00)
4043 goto op_semantics_24;
4049 switch (op[1] & 0x00)
4052 goto op_semantics_24;
4058 switch (op[1] & 0x00)
4061 goto op_semantics_24;
4067 switch (op[1] & 0x00)
4070 goto op_semantics_24;
4076 switch (op[1] & 0x00)
4079 goto op_semantics_24;
4085 switch (op[1] & 0x00)
4088 goto op_semantics_24;
4094 switch (op[1] & 0x00)
4097 goto op_semantics_24;
4103 switch (op[1] & 0x00)
4106 goto op_semantics_24;
4112 switch (op[1] & 0x00)
4115 goto op_semantics_24;
4121 switch (op[1] & 0x00)
4124 goto op_semantics_24;
4130 switch (op[1] & 0x00)
4133 goto op_semantics_24;
4139 switch (op[1] & 0x00)
4142 goto op_semantics_24;
4148 switch (op[1] & 0x00)
4151 goto op_semantics_24;
4157 switch (op[1] & 0x00)
4160 goto op_semantics_24;
4166 switch (op[1] & 0x00)
4169 goto op_semantics_24;
4175 switch (op[1] & 0x00)
4178 goto op_semantics_24;
4184 switch (op[1] & 0x00)
4187 goto op_semantics_24;
4193 switch (op[1] & 0x00)
4196 goto op_semantics_24;
4202 switch (op[1] & 0x00)
4205 goto op_semantics_24;
4211 switch (op[1] & 0x00)
4214 goto op_semantics_24;
4220 switch (op[1] & 0x00)
4223 goto op_semantics_24;
4229 switch (op[1] & 0x00)
4232 goto op_semantics_24;
4238 switch (op[1] & 0x00)
4241 goto op_semantics_24;
4247 switch (op[1] & 0x00)
4250 goto op_semantics_24;
4256 switch (op[1] & 0x00)
4259 goto op_semantics_24;
4265 switch (op[1] & 0x00)
4268 goto op_semantics_24;
4274 switch (op[1] & 0x00)
4277 goto op_semantics_24;
4283 switch (op[1] & 0x00)
4286 goto op_semantics_24;
4292 switch (op[1] & 0x00)
4295 goto op_semantics_24;
4301 switch (op[1] & 0x00)
4304 goto op_semantics_24;
4310 switch (op[1] & 0x00)
4313 goto op_semantics_24;
4319 switch (op[1] & 0x00)
4322 goto op_semantics_24;
4328 switch (op[1] & 0x00)
4331 goto op_semantics_24;
4337 switch (op[1] & 0x00)
4340 goto op_semantics_24;
4345 #line 590 "msp430-decode.opc"
4347 return msp430->n_bytes;