Lines Matching full:oc
328 bool Decoder::opcode_0xxxxxxx(const uint8_t *OC, unsigned &Offset, in opcode_0xxxxxxx() argument
330 uint8_t Imm = OC[Offset] & 0x7f; in opcode_0xxxxxxx()
332 OC[Offset], in opcode_0xxxxxxx()
339 bool Decoder::opcode_10Lxxxxx(const uint8_t *OC, unsigned &Offset, in opcode_10Lxxxxx() argument
341 unsigned Link = (OC[Offset] & 0x20) >> 5; in opcode_10Lxxxxx()
343 | ((OC[Offset + 0] & 0x1f) << 8) in opcode_10Lxxxxx()
344 | ((OC[Offset + 1] & 0xff) << 0); in opcode_10Lxxxxx()
349 OC[Offset + 0], OC[Offset + 1], in opcode_10Lxxxxx()
358 bool Decoder::opcode_1100xxxx(const uint8_t *OC, unsigned &Offset, in opcode_1100xxxx() argument
362 OC[Offset], OC[Offset] & 0xf); in opcode_1100xxxx()
365 OC[Offset], OC[Offset] & 0xf); in opcode_1100xxxx()
370 bool Decoder::opcode_11010Lxx(const uint8_t *OC, unsigned &Offset, in opcode_11010Lxx() argument
372 unsigned Link = (OC[Offset] & 0x4) >> 2; in opcode_11010Lxx()
373 unsigned Count = (OC[Offset] & 0x3); in opcode_11010Lxx()
378 SW.startLine() << format("0x%02x ; %s ", OC[Offset], in opcode_11010Lxx()
387 bool Decoder::opcode_11011Lxx(const uint8_t *OC, unsigned &Offset, in opcode_11011Lxx() argument
389 unsigned Link = (OC[Offset] & 0x4) >> 2; in opcode_11011Lxx()
390 unsigned Count = (OC[Offset] & 0x3) + 4; in opcode_11011Lxx()
395 SW.startLine() << format("0x%02x ; %s.w ", OC[Offset], in opcode_11011Lxx()
404 bool Decoder::opcode_11100xxx(const uint8_t *OC, unsigned &Offset, in opcode_11100xxx() argument
406 unsigned High = (OC[Offset] & 0x7); in opcode_11100xxx()
409 SW.startLine() << format("0x%02x ; %s ", OC[Offset], in opcode_11100xxx()
418 bool Decoder::opcode_111010xx(const uint8_t *OC, unsigned &Offset, in opcode_111010xx() argument
420 uint16_t Imm = ((OC[Offset + 0] & 0x03) << 8) | ((OC[Offset + 1] & 0xff) << 0); in opcode_111010xx()
423 OC[Offset + 0], OC[Offset + 1], in opcode_111010xx()
431 bool Decoder::opcode_1110110L(const uint8_t *OC, unsigned &Offset, in opcode_1110110L() argument
433 uint16_t GPRMask = ((OC[Offset + 0] & 0x01) << (Prologue ? 14 : 15)) in opcode_1110110L()
434 | ((OC[Offset + 1] & 0xff) << 0); in opcode_1110110L()
436 SW.startLine() << format("0x%02x 0x%02x ; %s ", OC[Offset + 0], in opcode_1110110L()
437 OC[Offset + 1], Prologue ? "push" : "pop"); in opcode_1110110L()
445 bool Decoder::opcode_11101110(const uint8_t *OC, unsigned &Offset, in opcode_11101110() argument
449 if (OC[Offset + 1] & 0xf0) in opcode_11101110()
451 OC[Offset + 0], OC[Offset + 1]); in opcode_11101110()
455 OC[Offset + 0], OC[Offset + 1], OC[Offset + 1] & 0x0f); in opcode_11101110()
461 bool Decoder::opcode_11101111(const uint8_t *OC, unsigned &Offset, in opcode_11101111() argument
463 if (OC[Offset + 1] & 0xf0) in opcode_11101111()
465 OC[Offset + 0], OC[Offset + 1]); in opcode_11101111()
469 OC[Offset + 0], OC[Offset + 1], OC[Offset + 1] << 2); in opcode_11101111()
473 OC[Offset + 0], OC[Offset + 1], OC[Offset + 1] << 2); in opcode_11101111()
479 bool Decoder::opcode_11110101(const uint8_t *OC, unsigned &Offset, in opcode_11110101() argument
481 unsigned Start = (OC[Offset + 1] & 0xf0) >> 4; in opcode_11110101()
482 unsigned End = (OC[Offset + 1] & 0x0f) >> 0; in opcode_11110101()
485 SW.startLine() << format("0x%02x 0x%02x ; %s ", OC[Offset + 0], in opcode_11110101()
486 OC[Offset + 1], Prologue ? "vpush" : "vpop"); in opcode_11110101()
494 bool Decoder::opcode_11110110(const uint8_t *OC, unsigned &Offset, in opcode_11110110() argument
496 unsigned Start = (OC[Offset + 1] & 0xf0) >> 4; in opcode_11110110()
497 unsigned End = (OC[Offset + 1] & 0x0f) >> 0; in opcode_11110110()
500 SW.startLine() << format("0x%02x 0x%02x ; %s ", OC[Offset + 0], in opcode_11110110()
501 OC[Offset + 1], Prologue ? "vpush" : "vpop"); in opcode_11110110()
509 bool Decoder::opcode_11110111(const uint8_t *OC, unsigned &Offset, in opcode_11110111() argument
511 uint32_t Imm = (OC[Offset + 1] << 8) | (OC[Offset + 2] << 0); in opcode_11110111()
514 OC[Offset + 0], OC[Offset + 1], OC[Offset + 2], in opcode_11110111()
522 bool Decoder::opcode_11111000(const uint8_t *OC, unsigned &Offset, in opcode_11111000() argument
524 uint32_t Imm = (OC[Offset + 1] << 16) in opcode_11111000()
525 | (OC[Offset + 2] << 8) in opcode_11111000()
526 | (OC[Offset + 3] << 0); in opcode_11111000()
530 OC[Offset + 0], OC[Offset + 1], OC[Offset + 2], OC[Offset + 3], in opcode_11111000()
537 bool Decoder::opcode_11111001(const uint8_t *OC, unsigned &Offset, in opcode_11111001() argument
539 uint32_t Imm = (OC[Offset + 1] << 8) | (OC[Offset + 2] << 0); in opcode_11111001()
543 OC[Offset + 0], OC[Offset + 1], OC[Offset + 2], in opcode_11111001()
550 bool Decoder::opcode_11111010(const uint8_t *OC, unsigned &Offset, in opcode_11111010() argument
552 uint32_t Imm = (OC[Offset + 1] << 16) in opcode_11111010()
553 | (OC[Offset + 2] << 8) in opcode_11111010()
554 | (OC[Offset + 3] << 0); in opcode_11111010()
558 OC[Offset + 0], OC[Offset + 1], OC[Offset + 2], OC[Offset + 3], in opcode_11111010()
565 bool Decoder::opcode_11111011(const uint8_t *OC, unsigned &Offset, in opcode_11111011() argument
567 SW.startLine() << format("0x%02x ; nop\n", OC[Offset]); in opcode_11111011()
572 bool Decoder::opcode_11111100(const uint8_t *OC, unsigned &Offset, in opcode_11111100() argument
574 SW.startLine() << format("0x%02x ; nop.w\n", OC[Offset]); in opcode_11111100()
579 bool Decoder::opcode_11111101(const uint8_t *OC, unsigned &Offset, in opcode_11111101() argument
581 SW.startLine() << format("0x%02x ; bx <reg>\n", OC[Offset]); in opcode_11111101()
586 bool Decoder::opcode_11111110(const uint8_t *OC, unsigned &Offset, in opcode_11111110() argument
588 SW.startLine() << format("0x%02x ; b.w <target>\n", OC[Offset]); in opcode_11111110()
593 bool Decoder::opcode_11111111(const uint8_t *OC, unsigned &Offset, in opcode_11111111() argument
600 bool Decoder::opcode_alloc_s(const uint8_t *OC, unsigned &Offset, in opcode_alloc_s() argument
602 uint32_t NumBytes = (OC[Offset] & 0x1F) << 4; in opcode_alloc_s()
603 SW.startLine() << format("0x%02x ; %s sp, #%u\n", OC[Offset], in opcode_alloc_s()
610 bool Decoder::opcode_save_r19r20_x(const uint8_t *OC, unsigned &Offset, in opcode_save_r19r20_x() argument
612 uint32_t Off = (OC[Offset] & 0x1F) << 3; in opcode_save_r19r20_x()
615 "0x%02x ; stp x19, x20, [sp, #-%u]!\n", OC[Offset], Off); in opcode_save_r19r20_x()
618 "0x%02x ; ldp x19, x20, [sp], #%u\n", OC[Offset], Off); in opcode_save_r19r20_x()
623 bool Decoder::opcode_save_fplr(const uint8_t *OC, unsigned &Offset, in opcode_save_fplr() argument
625 uint32_t Off = (OC[Offset] & 0x3F) << 3; in opcode_save_fplr()
627 "0x%02x ; %s x29, x30, [sp, #%u]\n", OC[Offset], in opcode_save_fplr()
633 bool Decoder::opcode_save_fplr_x(const uint8_t *OC, unsigned &Offset, in opcode_save_fplr_x() argument
635 uint32_t Off = ((OC[Offset] & 0x3F) + 1) << 3; in opcode_save_fplr_x()
638 "0x%02x ; stp x29, x30, [sp, #-%u]!\n", OC[Offset], Off); in opcode_save_fplr_x()
641 "0x%02x ; ldp x29, x30, [sp], #%u\n", OC[Offset], Off); in opcode_save_fplr_x()
646 bool Decoder::opcode_alloc_m(const uint8_t *OC, unsigned &Offset, in opcode_alloc_m() argument
648 uint32_t NumBytes = ((OC[Offset] & 0x07) << 8); in opcode_alloc_m()
649 NumBytes |= (OC[Offset + 1] & 0xFF); in opcode_alloc_m()
652 OC[Offset], OC[Offset + 1], in opcode_alloc_m()
659 bool Decoder::opcode_save_regp(const uint8_t *OC, unsigned &Offset, in opcode_save_regp() argument
661 uint32_t Reg = ((OC[Offset] & 0x03) << 8); in opcode_save_regp()
662 Reg |= (OC[Offset + 1] & 0xC0); in opcode_save_regp()
665 uint32_t Off = (OC[Offset + 1] & 0x3F) << 3; in opcode_save_regp()
668 OC[Offset], OC[Offset + 1], in opcode_save_regp()
674 bool Decoder::opcode_save_regp_x(const uint8_t *OC, unsigned &Offset, in opcode_save_regp_x() argument
676 uint32_t Reg = ((OC[Offset] & 0x03) << 8); in opcode_save_regp_x()
677 Reg |= (OC[Offset + 1] & 0xC0); in opcode_save_regp_x()
680 uint32_t Off = ((OC[Offset + 1] & 0x3F) + 1) << 3; in opcode_save_regp_x()
684 OC[Offset], OC[Offset + 1], Reg, in opcode_save_regp_x()
689 OC[Offset], OC[Offset + 1], Reg, in opcode_save_regp_x()
695 bool Decoder::opcode_save_reg(const uint8_t *OC, unsigned &Offset, in opcode_save_reg() argument
697 uint32_t Reg = (OC[Offset] & 0x03) << 8; in opcode_save_reg()
698 Reg |= (OC[Offset + 1] & 0xC0); in opcode_save_reg()
701 uint32_t Off = (OC[Offset + 1] & 0x3F) << 3; in opcode_save_reg()
703 OC[Offset], OC[Offset + 1], in opcode_save_reg()
710 bool Decoder::opcode_save_reg_x(const uint8_t *OC, unsigned &Offset, in opcode_save_reg_x() argument
712 uint32_t Reg = (OC[Offset] & 0x01) << 8; in opcode_save_reg_x()
713 Reg |= (OC[Offset + 1] & 0xE0); in opcode_save_reg_x()
716 uint32_t Off = ((OC[Offset + 1] & 0x1F) + 1) << 3; in opcode_save_reg_x()
719 OC[Offset], OC[Offset + 1], Reg, Off); in opcode_save_reg_x()
722 OC[Offset], OC[Offset + 1], Reg, Off); in opcode_save_reg_x()
727 bool Decoder::opcode_save_lrpair(const uint8_t *OC, unsigned &Offset, in opcode_save_lrpair() argument
729 uint32_t Reg = (OC[Offset] & 0x01) << 8; in opcode_save_lrpair()
730 Reg |= (OC[Offset + 1] & 0xC0); in opcode_save_lrpair()
734 uint32_t Off = (OC[Offset + 1] & 0x3F) << 3; in opcode_save_lrpair()
736 OC[Offset], OC[Offset + 1], in opcode_save_lrpair()
743 bool Decoder::opcode_save_fregp(const uint8_t *OC, unsigned &Offset, in opcode_save_fregp() argument
745 uint32_t Reg = (OC[Offset] & 0x01) << 8; in opcode_save_fregp()
746 Reg |= (OC[Offset + 1] & 0xC0); in opcode_save_fregp()
749 uint32_t Off = (OC[Offset + 1] & 0x3F) << 3; in opcode_save_fregp()
751 OC[Offset], OC[Offset + 1], in opcode_save_fregp()
758 bool Decoder::opcode_save_fregp_x(const uint8_t *OC, unsigned &Offset, in opcode_save_fregp_x() argument
760 uint32_t Reg = (OC[Offset] & 0x01) << 8; in opcode_save_fregp_x()
761 Reg |= (OC[Offset + 1] & 0xC0); in opcode_save_fregp_x()
764 uint32_t Off = ((OC[Offset + 1] & 0x3F) + 1) << 3; in opcode_save_fregp_x()
767 "0x%02x%02x ; stp d%u, d%u, [sp, #-%u]!\n", OC[Offset], in opcode_save_fregp_x()
768 OC[Offset + 1], Reg, Reg + 1, Off); in opcode_save_fregp_x()
771 "0x%02x%02x ; ldp d%u, d%u, [sp], #%u\n", OC[Offset], in opcode_save_fregp_x()
772 OC[Offset + 1], Reg, Reg + 1, Off); in opcode_save_fregp_x()
777 bool Decoder::opcode_save_freg(const uint8_t *OC, unsigned &Offset, in opcode_save_freg() argument
779 uint32_t Reg = (OC[Offset] & 0x01) << 8; in opcode_save_freg()
780 Reg |= (OC[Offset + 1] & 0xC0); in opcode_save_freg()
783 uint32_t Off = (OC[Offset + 1] & 0x3F) << 3; in opcode_save_freg()
785 OC[Offset], OC[Offset + 1], in opcode_save_freg()
792 bool Decoder::opcode_save_freg_x(const uint8_t *OC, unsigned &Offset, in opcode_save_freg_x() argument
794 uint32_t Reg = ((OC[Offset + 1] & 0xE0) >> 5) + 8; in opcode_save_freg_x()
795 uint32_t Off = ((OC[Offset + 1] & 0x1F) + 1) << 3; in opcode_save_freg_x()
798 "0x%02x%02x ; str d%u, [sp, #-%u]!\n", OC[Offset], in opcode_save_freg_x()
799 OC[Offset + 1], Reg, Off); in opcode_save_freg_x()
802 "0x%02x%02x ; ldr d%u, [sp], #%u\n", OC[Offset], in opcode_save_freg_x()
803 OC[Offset + 1], Reg, Off); in opcode_save_freg_x()
808 bool Decoder::opcode_alloc_l(const uint8_t *OC, unsigned &Offset, in opcode_alloc_l() argument
811 (OC[Offset + 1] << 16) | (OC[Offset + 2] << 8) | (OC[Offset + 3] << 0); in opcode_alloc_l()
814 "0x%02x%02x%02x%02x ; %s sp, #%u\n", OC[Offset], OC[Offset + 1], in opcode_alloc_l()
815 OC[Offset + 2], OC[Offset + 3], in opcode_alloc_l()
821 bool Decoder::opcode_setfp(const uint8_t *OC, unsigned &Offset, unsigned Length, in opcode_setfp() argument
823 SW.startLine() << format("0x%02x ; mov %s, %s\n", OC[Offset], in opcode_setfp()
830 bool Decoder::opcode_addfp(const uint8_t *OC, unsigned &Offset, unsigned Length, in opcode_addfp() argument
832 unsigned NumBytes = OC[Offset + 1] << 3; in opcode_addfp()
834 "0x%02x%02x ; %s %s, %s, #%u\n", OC[Offset], OC[Offset + 1], in opcode_addfp()
842 bool Decoder::opcode_nop(const uint8_t *OC, unsigned &Offset, unsigned Length, in opcode_nop() argument
844 SW.startLine() << format("0x%02x ; nop\n", OC[Offset]); in opcode_nop()
849 bool Decoder::opcode_end(const uint8_t *OC, unsigned &Offset, unsigned Length, in opcode_end() argument
851 SW.startLine() << format("0x%02x ; end\n", OC[Offset]); in opcode_end()
856 bool Decoder::opcode_end_c(const uint8_t *OC, unsigned &Offset, unsigned Length, in opcode_end_c() argument
858 SW.startLine() << format("0x%02x ; end_c\n", OC[Offset]); in opcode_end_c()
863 bool Decoder::opcode_save_next(const uint8_t *OC, unsigned &Offset, in opcode_save_next() argument
866 SW.startLine() << format("0x%02x ; save next\n", OC[Offset]); in opcode_save_next()
869 OC[Offset]); in opcode_save_next()
874 bool Decoder::opcode_save_any_reg(const uint8_t *OC, unsigned &Offset, in opcode_save_any_reg() argument
877 bool Writeback = (OC[Offset + 1] & 0x20) == 0x20; in opcode_save_any_reg()
880 bool Paired = (OC[Offset + 1] & 0x40) == 0x40; in opcode_save_any_reg()
885 int RegKind = (OC[Offset + 2] & 0xC0) >> 6; in opcode_save_any_reg()
887 int Reg = OC[Offset + 1] & 0x1F; in opcode_save_any_reg()
889 int StackOffset = OC[Offset + 2] & 0x3F; in opcode_save_any_reg()
897 SW.startLine() << format("0x%02x%02x%02x ; ", OC[Offset], in opcode_save_any_reg()
898 OC[Offset + 1], OC[Offset + 2]); in opcode_save_any_reg()
908 if ((OC[Offset + 1] & 0x80) == 0x80 || RegKind == 3 || Reg > MaxReg) { in opcode_save_any_reg()
951 bool Decoder::opcode_trap_frame(const uint8_t *OC, unsigned &Offset, in opcode_trap_frame() argument
953 SW.startLine() << format("0x%02x ; trap frame\n", OC[Offset]); in opcode_trap_frame()
958 bool Decoder::opcode_machine_frame(const uint8_t *OC, unsigned &Offset, in opcode_machine_frame() argument
961 OC[Offset]); in opcode_machine_frame()
966 bool Decoder::opcode_context(const uint8_t *OC, unsigned &Offset, in opcode_context() argument
968 SW.startLine() << format("0x%02x ; context\n", OC[Offset]); in opcode_context()
973 bool Decoder::opcode_ec_context(const uint8_t *OC, unsigned &Offset, in opcode_ec_context() argument
975 SW.startLine() << format("0x%02x ; EC context\n", OC[Offset]); in opcode_ec_context()
980 bool Decoder::opcode_clear_unwound_to_call(const uint8_t *OC, unsigned &Offset, in opcode_clear_unwound_to_call() argument
983 OC[Offset]); in opcode_clear_unwound_to_call()
988 bool Decoder::opcode_pac_sign_lr(const uint8_t *OC, unsigned &Offset, in opcode_pac_sign_lr() argument
991 SW.startLine() << format("0x%02x ; pacibsp\n", OC[Offset]); in opcode_pac_sign_lr()
993 SW.startLine() << format("0x%02x ; autibsp\n", OC[Offset]); in opcode_pac_sign_lr()