📄 ops.h
字号:
#define O_BITB 0x93 /* bit test byte */#define O_CLRB 0x94 /* clear byte */#define O_TSTB 0x95 /* test byte */#define O_INCB 0x96 /* increment byte */#define O_DECB 0x97 /* decrement byte */#define O_CVTBL 0x98 /* convert byte to long */#define O_CVTBW 0x99 /* convert byte to word */#define O_MOVZBL 0x9A /* move zero-extended byte to long */#define O_MOVZBW 0x9B /* move zero-extended byte to word */#define O_ROTL 0x9C /* rotate long */#define O_ACBB 0x9D /* add compare and branch byte */#define O_MOVAB 0x9E /* move address of byte */#define O_PUSHAB 0x9F /* push address of byte */#define O_ADDW2 0xA0 /* add word 2 operand */#define O_ADDW3 0xA1 /* add word 3 operand */#define O_SUBW2 0xA2 /* subtract word 2 operand */#define O_SUBW3 0xA3 /* subtract word 3 operand */#define O_MULW2 0xA4 /* multiply word 2 operand */#define O_MULW3 0xA5 /* multiply word 3 operand */#define O_DIVW2 0xA6 /* divide word 2 operand */#define O_DIVW3 0xA7 /* divide word 3 operand */#define O_BISW2 0xA8 /* bit set word 2 operand */#define O_BISW3 0xA9 /* bit set word 3 operand */#define O_BICW2 0xAA /* bit clear word 2 operand */#define O_BICW3 0xAB /* bit clear word 3 operand */#define O_XORW2 0xAC /* exclusive or word 2 operand */#define O_XORW3 0xAD /* exclusive or word 3 operand */#define O_MNEGW 0xAE /* move negated word */#define O_CASEW 0xAF /* case word */#define O_MOVW 0xB0 /* move word */#define O_CMPW 0xB1 /* compare word */#define O_MCOMW 0xB2 /* move complemented word */#define O_BITW 0xB3 /* bit test word */#define O_CLRW 0xB4 /* clear word */#define O_TSTW 0xB5 /* test word */#define O_INCW 0xB6 /* increment word */#define O_DECW 0xB7 /* decrement word */#define O_BISPSW 0xB8 /* bit set processor status word */#define O_BICPSW 0xB9 /* bit clear processor status word */#define O_POPR 0xBA /* pop register */#define O_PUSHR 0xBB /* push register */#define O_CHMK 0xBC /* change mode to kernel */#define O_CHME 0xBD /* change mode to executive */#define O_CHMS 0xBE /* change mode to supervisor */#define O_CHMU 0xBF /* change mode to user */#define O_ADDL2 0xC0 /* add long 2 operand */#define O_ADDL3 0xC1 /* add long 3 operand */#define O_SUBL2 0xC2 /* subtract long 2 operand */#define O_SUBL3 0xC3 /* subtract long 3 operand */#define O_MULL2 0xC4 /* multiply long 2 operand */#define O_MULL3 0xC5 /* multiply long 3 operand */#define O_DIVL2 0xC6 /* divide long 2 operand */#define O_DIVL3 0xC7 /* divide long 3 operand */#define O_BISL2 0xC8 /* bit set long 2 operand */#define O_BISL3 0xC9 /* bit set long 3 operand */#define O_BICL2 0xCA /* bit clear long 2 operand */#define O_BICL3 0xCB /* bit clear long 3 operand */#define O_XORL2 0xCC /* exclusive or long 2 operand */#define O_XORL3 0xCD /* exclusive or long 3 operand */#define O_MNEGL 0xCE /* move negated long */#define O_CASEL 0xCF /* case long */#define O_MOVL 0xD0 /* move long */#define O_CMPL 0xD1 /* compare long */#define O_MCOML 0xD2 /* move complemented long */#define O_BITL 0xD3 /* bit test long */#define O_CLRL 0xD4 /* clear long (also CLRF) */#define O_TSTL 0xD5 /* test long */#define O_INCL 0xD6 /* increment long */#define O_DECL 0xD7 /* decrement long */#define O_ADWC 0xD8 /* add with carry */#define O_SBWC 0xD9 /* subtrace with carry */#define O_MTPR 0xDA /* move to processor register */#define O_MFPR 0xDB /* move from processor register */#define O_MOVPSL 0xDC /* move processor status longword */#define O_PUSHL 0xDD /* push long */#define O_MOVAL 0xDE /* move address of long (also MOVAF) */#define O_PUSHAL 0xDF /* push address of long (also PUSHAF) */#define O_BBS 0xE0 /* branch on bit set */#define O_BBC 0xE1 /* branch on bit clear */#define O_BBSS 0xE2 /* branch on bit set and set */#define O_BBCS 0xE3 /* branch on bit clear and set */#define O_BBSC 0xE4 /* branch on bit set and clear */#define O_BBCC 0xE5 /* branch on bit clear and clear */#define O_BBSSI 0xE6 /* branch on bit set and set interlocked */#define O_BBCCI 0xE7 /* branch on bit clear and clear interlocked */#define O_BLBS 0xE8 /* branch on low bit set */#define O_BLBC 0xE9 /* branch on low bit clear */#define O_FFS 0xEA /* find first set bit */#define O_FFC 0xEB /* find first clear bit */#define O_CMPV 0xEC /* compare field */#define O_CMPZV 0xED /* compare zero-extended field */#define O_EXTV 0xEE /* extract field */#define O_EXTZV 0xEF /* extract zero-extended field */#define O_INSV 0xF0 /* insert field */#define O_ACBL 0xF1 /* add compare and branch long */#define O_AOBLSS 0xF2 /* add one and branch on less */#define O_AOBLEQ 0xF3 /* add one and branch on less or equal */#define O_SOBGEQ 0xF4 /* subtract one and branch on gtr or equal */#define O_SOBGTR 0xF5 /* subtract one and branch on greater */#define O_CVTLB 0xF6 /* convert long to byte */#define O_CVTLW 0xF7 /* convert long to word */#define O_ASHP 0xF8 /* arithmetic shift and round packed */#define O_CVTLP 0xF9 /* convert long to packed */#define O_CALLG 0xFA /* call with general argument list */#define O_CALLS 0xFB /* call with stack */#define O_XFC 0xFC /* extended function call */#define O_ESCD 0xFD /* ESCD to DIGITAL */#define O_ESCE 0xFE /* ESCE to DIGITAL */#define O_ESCF 0xFF /* ESCF to DIGITAL *//* * Opcode definitions. * * Much of this was taken from the assembler. *//* * Argument access types. */#define ACCA 0100 /* address only */#define ACCR 010 /* read */#define ACCW 020 /* write */#define ACCM 030 /* modify */#define ACCB 040 /* branch displacement */#define ACCI 050 /* variable field *//* * Argument lengths. */#define TYPB 0 /* byte */#define TYPW 01 /* word */#define TYPL 02 /* long */#define TYPQ 03 /* quad */#define TYPF 04 /* floating */#define TYPD 05 /* double floating *//* * Addressing modes. */#define LITSHORT 0x0 /* short literals */#define LITUPTO31 0x1#define LITUPTO47 0x2#define LITUPTO63 0x3#define INDEX 0x4 /* i[r] */#define REG 0x5 /* r */#define REGDEF 0x6 /* (r) */#define AUTODEC 0x7 /* -(r) */#define AUTOINC 0x8 /* (r)+ */#define AUTOINCDEF 0x9 /* *(r)+ */#define BYTEDISP 0xA /* BD(r) */#define BYTEDISPDEF 0xB /* *BD(r) */#define WORDDISP 0xC /* WD(r) */#define WORDDISPDEF 0xD /* *WD(r) */#define LONGDISP 0xE /* LD(r) */#define LONGDISPDEF 0xF /* *LD(r) */#define is_branch_disp(arg) ((arg & ACCB) != 0)#define typelen(arg) (arg & 07)#define regnm(mode) (mode & 0xF)#define addrmode(mode) (mode >> 4)/* * Operator information structure. */typedef struct { char *iname; char val; char numargs; char argtype[6];} Optab;Optab optab[500] ;String regname[100] ;String fltimm[100] ;#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -