comparison lwasm/instab.c @ 364:44270b66df3c

Add some compatibility ops Add compatibility opcodes for other assemblers. Thanks to Erik G <erik@6809.org> for the patch.
author William Astle <lost@l-w.ca>
date Mon, 01 Jun 2015 19:55:11 -0600
parents fa3659ffa834
children c6d2a1f54e0c
comparison
equal deleted inserted replaced
363:f90c9b044220 364:44270b66df3c
519 { "puls", { 0x35, -1, -1, -1 }, insn_parse_rlist, insn_resolve_rlist, insn_emit_rlist, lwasm_insn_normal}, 519 { "puls", { 0x35, -1, -1, -1 }, insn_parse_rlist, insn_resolve_rlist, insn_emit_rlist, lwasm_insn_normal},
520 { "pulsw", { 0x1039, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_is6309}, 520 { "pulsw", { 0x1039, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_is6309},
521 { "pulu", { 0x37, -1, -1, -1 }, insn_parse_rlist, insn_resolve_rlist, insn_emit_rlist, lwasm_insn_normal}, 521 { "pulu", { 0x37, -1, -1, -1 }, insn_parse_rlist, insn_resolve_rlist, insn_emit_rlist, lwasm_insn_normal},
522 { "puluw", { 0x103b, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_is6309}, 522 { "puluw", { 0x103b, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_is6309},
523 523
524 { "reset", { 0x3e, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_normal},
524 { "rol", { 0x09, 0x69, 0x79, -1 }, insn_parse_gen0, insn_resolve_gen0, insn_emit_gen0, lwasm_insn_normal}, 525 { "rol", { 0x09, 0x69, 0x79, -1 }, insn_parse_gen0, insn_resolve_gen0, insn_emit_gen0, lwasm_insn_normal},
525 { "rola", { 0x49, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_normal}, 526 { "rola", { 0x49, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_normal},
526 { "rolb", { 0x59, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_normal}, 527 { "rolb", { 0x59, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_normal},
527 { "rold", { 0x1049, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_is6309}, 528 { "rold", { 0x1049, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_is6309},
528 { "rolw", { 0x1059, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_is6309}, 529 { "rolw", { 0x1059, -1, -1, -1 }, insn_parse_inh, insn_resolve_inh, insn_emit_inh, lwasm_insn_is6309},
607 { "rmd", { -1, -1, -1, -1 }, pseudo_parse_rmd, pseudo_resolve_rmd, pseudo_emit_rmd, lwasm_insn_struct | lwasm_insn_setdata}, 608 { "rmd", { -1, -1, -1, -1 }, pseudo_parse_rmd, pseudo_resolve_rmd, pseudo_emit_rmd, lwasm_insn_struct | lwasm_insn_setdata},
608 { "rmw", { -1, -1, -1, -1 }, pseudo_parse_rmd, pseudo_resolve_rmd, pseudo_emit_rmd, lwasm_insn_struct | lwasm_insn_setdata}, 609 { "rmw", { -1, -1, -1, -1 }, pseudo_parse_rmd, pseudo_resolve_rmd, pseudo_emit_rmd, lwasm_insn_struct | lwasm_insn_setdata},
609 { "rmq", { -1, -1, -1, -1 }, pseudo_parse_rmq, pseudo_resolve_rmq, pseudo_emit_rmq, lwasm_insn_struct | lwasm_insn_setdata}, 610 { "rmq", { -1, -1, -1, -1 }, pseudo_parse_rmq, pseudo_resolve_rmq, pseudo_emit_rmq, lwasm_insn_struct | lwasm_insn_setdata},
610 611
611 { "zmb", { -1, -1, -1, -1 }, pseudo_parse_zmb, pseudo_resolve_zmb, pseudo_emit_zmb, lwasm_insn_normal}, 612 { "zmb", { -1, -1, -1, -1 }, pseudo_parse_zmb, pseudo_resolve_zmb, pseudo_emit_zmb, lwasm_insn_normal},
613 { "bsz", { -1, -1, -1, -1 }, pseudo_parse_zmb, pseudo_resolve_zmb, pseudo_emit_zmb, lwasm_insn_normal},
612 { "fzb", { -1, -1, -1, -1 }, pseudo_parse_zmb, pseudo_resolve_zmb, pseudo_emit_zmb, lwasm_insn_normal}, 614 { "fzb", { -1, -1, -1, -1 }, pseudo_parse_zmb, pseudo_resolve_zmb, pseudo_emit_zmb, lwasm_insn_normal},
613 { "zmd", { -1, -1, -1, -1 }, pseudo_parse_zmd, pseudo_resolve_zmd, pseudo_emit_zmd, lwasm_insn_normal}, 615 { "zmd", { -1, -1, -1, -1 }, pseudo_parse_zmd, pseudo_resolve_zmd, pseudo_emit_zmd, lwasm_insn_normal},
614 { "zmq", { -1, -1, -1, -1 }, pseudo_parse_zmq, pseudo_resolve_zmq, pseudo_emit_zmq, lwasm_insn_normal}, 616 { "zmq", { -1, -1, -1, -1 }, pseudo_parse_zmq, pseudo_resolve_zmq, pseudo_emit_zmq, lwasm_insn_normal},
615 617
616 { "fcc", { -1, -1, -1, -1 }, pseudo_parse_fcc, pseudo_resolve_fcc, pseudo_emit_fcc, lwasm_insn_normal}, 618 { "fcc", { -1, -1, -1, -1 }, pseudo_parse_fcc, pseudo_resolve_fcc, pseudo_emit_fcc, lwasm_insn_normal},
623 { "fqb", { -1, -1, -1, -1 }, pseudo_parse_fqb, pseudo_resolve_fqb, pseudo_emit_fqb, lwasm_insn_normal}, 625 { "fqb", { -1, -1, -1, -1 }, pseudo_parse_fqb, pseudo_resolve_fqb, pseudo_emit_fqb, lwasm_insn_normal},
624 { "end", { -1, -1, -1, -1 }, pseudo_parse_end, pseudo_resolve_end, pseudo_emit_end, lwasm_insn_normal}, 626 { "end", { -1, -1, -1, -1 }, pseudo_parse_end, pseudo_resolve_end, pseudo_emit_end, lwasm_insn_normal},
625 627
626 { "includebin", { -1, -1, -1, -1}, pseudo_parse_includebin,pseudo_resolve_includebin, pseudo_emit_includebin, lwasm_insn_normal}, 628 { "includebin", { -1, -1, -1, -1}, pseudo_parse_includebin,pseudo_resolve_includebin, pseudo_emit_includebin, lwasm_insn_normal},
627 { "include", { -1, -1, -1, -1 }, pseudo_parse_include, pseudo_resolve_include, pseudo_emit_include, lwasm_insn_normal}, 629 { "include", { -1, -1, -1, -1 }, pseudo_parse_include, pseudo_resolve_include, pseudo_emit_include, lwasm_insn_normal},
630 { "incl", { -1, -1, -1, -1 }, pseudo_parse_include, pseudo_resolve_include, pseudo_emit_include, lwasm_insn_normal},
628 { "use", { -1, -1, -1, -1 }, pseudo_parse_include, pseudo_resolve_include, pseudo_emit_include, lwasm_insn_normal}, 631 { "use", { -1, -1, -1, -1 }, pseudo_parse_include, pseudo_resolve_include, pseudo_emit_include, lwasm_insn_normal},
629 632
630 { "align", { -1, -1, -1, -1 }, pseudo_parse_align, pseudo_resolve_align, pseudo_emit_align, lwasm_insn_normal}, 633 { "align", { -1, -1, -1, -1 }, pseudo_parse_align, pseudo_resolve_align, pseudo_emit_align, lwasm_insn_normal},
631 { "fill", { -1, -1, -1, -1 }, pseudo_parse_fill, pseudo_resolve_fill, pseudo_emit_fill, lwasm_insn_normal}, 634 { "fill", { -1, -1, -1, -1 }, pseudo_parse_fill, pseudo_resolve_fill, pseudo_emit_fill, lwasm_insn_normal},
632 635
633 { "error", { -1, -1, -1, -1}, pseudo_parse_error, pseudo_resolve_error, pseudo_emit_error, lwasm_insn_normal}, 636 { "error", { -1, -1, -1, -1}, pseudo_parse_error, pseudo_resolve_error, pseudo_emit_error, lwasm_insn_normal},
634 { "warning", { -1, -1, -1, -1}, pseudo_parse_warning, pseudo_resolve_warning, pseudo_emit_warning, lwasm_insn_normal}, 637 { "warning", { -1, -1, -1, -1}, pseudo_parse_warning, pseudo_resolve_warning, pseudo_emit_warning, lwasm_insn_normal},
638 { "msg", { -1, -1, -1, -1}, pseudo_parse_warning, pseudo_resolve_warning, pseudo_emit_warning, lwasm_insn_normal},
635 639
636 // these are *dangerous* 640 // these are *dangerous*
637 { "ifp1", { -1, -1, -1, -1}, pseudo_parse_ifp1, pseudo_resolve_ifp1, pseudo_emit_ifp1, lwasm_insn_cond}, 641 { "ifp1", { -1, -1, -1, -1}, pseudo_parse_ifp1, pseudo_resolve_ifp1, pseudo_emit_ifp1, lwasm_insn_cond},
638 { "ifp2", { -1, -1, -1, -1}, pseudo_parse_ifp2, pseudo_resolve_ifp2, pseudo_emit_ifp2, lwasm_insn_cond}, 642 { "ifp2", { -1, -1, -1, -1}, pseudo_parse_ifp2, pseudo_resolve_ifp2, pseudo_emit_ifp2, lwasm_insn_cond},
639 643
652 656
653 // string operations, mostly useful in macros 657 // string operations, mostly useful in macros
654 { "ifstr", { -1, -1, -1, -1}, pseudo_parse_ifstr, pseudo_resolve_ifstr, pseudo_emit_ifstr, lwasm_insn_cond}, 658 { "ifstr", { -1, -1, -1, -1}, pseudo_parse_ifstr, pseudo_resolve_ifstr, pseudo_emit_ifstr, lwasm_insn_cond},
655 659
656 { "macro", { -1, -1, -1, -1}, pseudo_parse_macro, pseudo_resolve_macro, pseudo_emit_macro, lwasm_insn_cond | lwasm_insn_setsym}, 660 { "macro", { -1, -1, -1, -1}, pseudo_parse_macro, pseudo_resolve_macro, pseudo_emit_macro, lwasm_insn_cond | lwasm_insn_setsym},
661 { "macr", { -1, -1, -1, -1}, pseudo_parse_macro, pseudo_resolve_macro, pseudo_emit_macro, lwasm_insn_cond | lwasm_insn_setsym},
657 { "endm", { -1, -1, -1, -1}, pseudo_parse_endm, pseudo_resolve_endm, pseudo_emit_endm, lwasm_insn_cond | lwasm_insn_setsym | lwasm_insn_endm}, 662 { "endm", { -1, -1, -1, -1}, pseudo_parse_endm, pseudo_resolve_endm, pseudo_emit_endm, lwasm_insn_cond | lwasm_insn_setsym | lwasm_insn_endm},
658 663
659 { "setdp", { -1, -1, -1, -1}, pseudo_parse_setdp, pseudo_resolve_setdp, pseudo_emit_setdp, lwasm_insn_normal}, 664 { "setdp", { -1, -1, -1, -1}, pseudo_parse_setdp, pseudo_resolve_setdp, pseudo_emit_setdp, lwasm_insn_normal},
660 { "set", { -1, -1, -1, -1}, pseudo_parse_set, pseudo_resolve_set, pseudo_emit_set, lwasm_insn_setsym}, 665 { "set", { -1, -1, -1, -1}, pseudo_parse_set, pseudo_resolve_set, pseudo_emit_set, lwasm_insn_setsym},
661 666
733 { "clc", { 0x1cfe, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 }, 738 { "clc", { 0x1cfe, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 },
734 { "clf", { 0x1cbf, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 }, 739 { "clf", { 0x1cbf, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 },
735 { "cli", { 0x1cef, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 }, 740 { "cli", { 0x1cef, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 },
736 { "clif", { 0x1caf, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 }, 741 { "clif", { 0x1caf, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 },
737 { "clv", { 0x1cfd, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 }, 742 { "clv", { 0x1cfd, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 },
743 { "cpx", { 0x9c, 0xac, 0xbc, 0x8c }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 },
738 { "des", { 0x327f, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 }, 744 { "des", { 0x327f, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 },
739 { "dex", { 0x301f, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 }, 745 { "dex", { 0x301f, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 },
740 { "dey", { 0x313f, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 }, 746 { "dey", { 0x313f, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 },
741 { "ins", { 0x3261, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 }, 747 { "ins", { 0x3261, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 },
742 { "inx", { 0x3001, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 }, 748 { "inx", { 0x3001, -1, -1, -1 }, insn_parse_inh6800, insn_resolve_inh6800, insn_emit_inh6800, lwasm_insn_is6800 },