mos65xx.h
Go to the documentation of this file.
1 #ifndef CAPSTONE_MOS65XX_H
2 #define CAPSTONE_MOS65XX_H
3 
4 /* Capstone Disassembly Engine */
5 /* By Sebastian Macke <sebastian@macke.de, 2018 */
6 
7 #ifdef __cplusplus
8 extern "C" {
9 #endif
10 
11 #include "platform.h"
12 
14 typedef enum mos65xx_reg {
21  MOS65XX_REG_ENDING, // <-- mark the end of the list of registers
22 } mos65xx_reg;
23 
25 typedef enum mos65xx_address_mode {
41 
43 typedef enum mos65xx_insn {
101  MOS65XX_INS_ENDING, // <-- mark the end of the list of instructions
102 } mos65xx_insn;
103 
105 typedef enum mos65xx_group_type {
112  MOS65XX_GRP_ENDING,// <-- mark the end of the list of groups
114 
116 typedef enum mos65xx_op_type {
122 
124 typedef struct cs_mos65xx_op {
126  union {
130  };
131 } cs_mos65xx_op;
132 
134 typedef struct cs_mos65xx {
137 
142 } cs_mos65xx;
143 
144 #ifdef __cplusplus
145 }
146 #endif
147 
148 #endif //CAPSTONE_MOS65XX_H
MOS65XX_INS_BNE
@ MOS65XX_INS_BNE
Definition: mos65xx.h:53
MOS65XX_INS_BPL
@ MOS65XX_INS_BPL
Definition: mos65xx.h:54
MOS65XX_INS_ENDING
@ MOS65XX_INS_ENDING
Definition: mos65xx.h:101
MOS65XX_INS_CPX
@ MOS65XX_INS_CPX
Definition: mos65xx.h:63
MOS65XX_INS_TSX
@ MOS65XX_INS_TSX
Definition: mos65xx.h:97
MOS65XX_INS_BVS
@ MOS65XX_INS_BVS
Definition: mos65xx.h:57
MOS65XX_INS_BRK
@ MOS65XX_INS_BRK
Definition: mos65xx.h:55
MOS65XX_AM_IMM
@ MOS65XX_AM_IMM
8 Bit immediate value
Definition: mos65xx.h:31
MOS65XX_INS_AND
@ MOS65XX_INS_AND
Definition: mos65xx.h:46
MOS65XX_AM_ABS
@ MOS65XX_AM_ABS
absolute addressing
Definition: mos65xx.h:29
MOS65XX_INS_SBC
@ MOS65XX_INS_SBC
Definition: mos65xx.h:88
MOS65XX_AM_INDX
@ MOS65XX_AM_INDX
indexed indirect addressing by the X index register
Definition: mos65xx.h:34
uint16_t
unsigned short uint16_t
Definition: stdint-msvc2008.h:79
cs_mos65xx_op
struct cs_mos65xx_op cs_mos65xx_op
Instruction operand.
cs_mos65xx::am
mos65xx_address_mode am
Definition: mos65xx.h:135
MOS65XX_AM_ZPX
@ MOS65XX_AM_ZPX
indexed zeropage addressing by the X index register
Definition: mos65xx.h:36
MOS65XX_INS_CMP
@ MOS65XX_INS_CMP
Definition: mos65xx.h:62
mos65xx_group_type
mos65xx_group_type
Group of MOS65XX instructions.
Definition: mos65xx.h:105
MOS65XX_INS_INX
@ MOS65XX_INS_INX
Definition: mos65xx.h:70
MOS65XX_INS_NOP
@ MOS65XX_INS_NOP
Definition: mos65xx.h:78
MOS65XX_INS_INVALID
@ MOS65XX_INS_INVALID
Definition: mos65xx.h:44
MOS65XX_AM_IMP
@ MOS65XX_AM_IMP
implied addressing (no addressing mode)
Definition: mos65xx.h:27
MOS65XX_INS_TXA
@ MOS65XX_INS_TXA
Definition: mos65xx.h:98
MOS65XX_AM_ABSX
@ MOS65XX_AM_ABSX
indexed absolute addressing by the X index register
Definition: mos65xx.h:32
MOS65XX_INS_BMI
@ MOS65XX_INS_BMI
Definition: mos65xx.h:52
MOS65XX_GRP_JUMP
@ MOS65XX_GRP_JUMP
= CS_GRP_JUMP
Definition: mos65xx.h:107
uint8_t
unsigned char uint8_t
Definition: stdint-msvc2008.h:78
MOS65XX_INS_ADC
@ MOS65XX_INS_ADC
Definition: mos65xx.h:45
MOS65XX_GRP_IRET
@ MOS65XX_GRP_IRET
= CS_GRP_IRET
Definition: mos65xx.h:110
MOS65XX_REG_ENDING
@ MOS65XX_REG_ENDING
Definition: mos65xx.h:21
MOS65XX_INS_CLC
@ MOS65XX_INS_CLC
Definition: mos65xx.h:58
cs_mos65xx
struct cs_mos65xx cs_mos65xx
The MOS65XX address mode and it's operands.
MOS65XX_INS_TAY
@ MOS65XX_INS_TAY
Definition: mos65xx.h:96
MOS65XX_INS_ASL
@ MOS65XX_INS_ASL
Definition: mos65xx.h:47
MOS65XX_INS_SEI
@ MOS65XX_INS_SEI
Definition: mos65xx.h:91
MOS65XX_INS_TYA
@ MOS65XX_INS_TYA
Definition: mos65xx.h:100
MOS65XX_INS_STY
@ MOS65XX_INS_STY
Definition: mos65xx.h:94
MOS65XX_AM_REL
@ MOS65XX_AM_REL
relative addressing used by branches
Definition: mos65xx.h:38
MOS65XX_INS_JMP
@ MOS65XX_INS_JMP
Definition: mos65xx.h:72
MOS65XX_INS_INC
@ MOS65XX_INS_INC
Definition: mos65xx.h:69
MOS65XX_INS_STX
@ MOS65XX_INS_STX
Definition: mos65xx.h:93
MOS65XX_INS_BCC
@ MOS65XX_INS_BCC
Definition: mos65xx.h:48
MOS65XX_REG_X
@ MOS65XX_REG_X
X index register.
Definition: mos65xx.h:17
MOS65XX_GRP_BRANCH_RELATIVE
@ MOS65XX_GRP_BRANCH_RELATIVE
= CS_GRP_BRANCH_RELATIVE
Definition: mos65xx.h:111
MOS65XX_INS_SEC
@ MOS65XX_INS_SEC
Definition: mos65xx.h:89
MOS65XX_AM_ZPY
@ MOS65XX_AM_ZPY
indexed zeropage addressing by the Y index register
Definition: mos65xx.h:37
MOS65XX_GRP_INVALID
@ MOS65XX_GRP_INVALID
CS_GRP_INVALID.
Definition: mos65xx.h:106
MOS65XX_INS_BIT
@ MOS65XX_INS_BIT
Definition: mos65xx.h:51
mos65xx_op_type
mos65xx_op_type
Operand type for instruction's operands.
Definition: mos65xx.h:116
MOS65XX_OP_REG
@ MOS65XX_OP_REG
= CS_OP_REG (Register operand).
Definition: mos65xx.h:118
MOS65XX_INS_CLD
@ MOS65XX_INS_CLD
Definition: mos65xx.h:59
MOS65XX_AM_NONE
@ MOS65XX_AM_NONE
No address mode.
Definition: mos65xx.h:26
cs_mos65xx::modifies_flags
bool modifies_flags
Definition: mos65xx.h:136
MOS65XX_INS_CPY
@ MOS65XX_INS_CPY
Definition: mos65xx.h:64
MOS65XX_GRP_ENDING
@ MOS65XX_GRP_ENDING
Definition: mos65xx.h:112
MOS65XX_INS_DEY
@ MOS65XX_INS_DEY
Definition: mos65xx.h:67
platform.h
MOS65XX_INS_PLP
@ MOS65XX_INS_PLP
Definition: mos65xx.h:83
MOS65XX_INS_INY
@ MOS65XX_INS_INY
Definition: mos65xx.h:71
MOS65XX_INS_ORA
@ MOS65XX_INS_ORA
Definition: mos65xx.h:79
MOS65XX_INS_TAX
@ MOS65XX_INS_TAX
Definition: mos65xx.h:95
cs_mos65xx_op::reg
mos65xx_reg reg
register value for REG operand
Definition: mos65xx.h:127
MOS65XX_INS_BEQ
@ MOS65XX_INS_BEQ
Definition: mos65xx.h:50
MOS65XX_AM_ZP
@ MOS65XX_AM_ZP
zeropage addressing
Definition: mos65xx.h:30
MOS65XX_GRP_CALL
@ MOS65XX_GRP_CALL
= CS_GRP_RET
Definition: mos65xx.h:108
cs_mos65xx_op::imm
uint8_t imm
immediate value for IMM operand
Definition: mos65xx.h:128
MOS65XX_REG_INVALID
@ MOS65XX_REG_INVALID
Definition: mos65xx.h:15
MOS65XX_OP_MEM
@ MOS65XX_OP_MEM
= CS_OP_MEM (Memory operand).
Definition: mos65xx.h:120
MOS65XX_INS_TXS
@ MOS65XX_INS_TXS
Definition: mos65xx.h:99
MOS65XX_INS_BCS
@ MOS65XX_INS_BCS
Definition: mos65xx.h:49
MOS65XX_INS_DEC
@ MOS65XX_INS_DEC
Definition: mos65xx.h:65
MOS65XX_INS_EOR
@ MOS65XX_INS_EOR
Definition: mos65xx.h:68
cs_mos65xx::operands
cs_mos65xx_op operands[3]
operands for this instruction.
Definition: mos65xx.h:141
mos65xx_address_mode
mos65xx_address_mode
MOS65XX Addressing Modes.
Definition: mos65xx.h:25
MOS65XX_INS_STA
@ MOS65XX_INS_STA
Definition: mos65xx.h:92
cs_mos65xx
The MOS65XX address mode and it's operands.
Definition: mos65xx.h:134
MOS65XX_REG_SP
@ MOS65XX_REG_SP
stack pointer register
Definition: mos65xx.h:20
MOS65XX_INS_ROR
@ MOS65XX_INS_ROR
Definition: mos65xx.h:85
cs_mos65xx::op_count
uint8_t op_count
Definition: mos65xx.h:140
MOS65XX_INS_PHP
@ MOS65XX_INS_PHP
Definition: mos65xx.h:82
MOS65XX_AM_IND
@ MOS65XX_AM_IND
absolute indirect addressing
Definition: mos65xx.h:39
MOS65XX_INS_LDX
@ MOS65XX_INS_LDX
Definition: mos65xx.h:75
cs_mos65xx_op::mem
uint16_t mem
base/index/scale/disp value for MEM operand
Definition: mos65xx.h:129
cs_mos65xx_op
Instruction operand.
Definition: mos65xx.h:124
MOS65XX_REG_Y
@ MOS65XX_REG_Y
Y index register.
Definition: mos65xx.h:18
MOS65XX_INS_CLI
@ MOS65XX_INS_CLI
Definition: mos65xx.h:60
MOS65XX_INS_LSR
@ MOS65XX_INS_LSR
Definition: mos65xx.h:77
mos65xx_insn
mos65xx_insn
MOS65XX instruction.
Definition: mos65xx.h:43
MOS65XX_INS_RTS
@ MOS65XX_INS_RTS
Definition: mos65xx.h:87
MOS65XX_INS_LDA
@ MOS65XX_INS_LDA
Definition: mos65xx.h:74
MOS65XX_REG_P
@ MOS65XX_REG_P
status register
Definition: mos65xx.h:19
MOS65XX_INS_SED
@ MOS65XX_INS_SED
Definition: mos65xx.h:90
MOS65XX_INS_RTI
@ MOS65XX_INS_RTI
Definition: mos65xx.h:86
MOS65XX_OP_IMM
@ MOS65XX_OP_IMM
= CS_OP_IMM (Immediate operand).
Definition: mos65xx.h:119
MOS65XX_INS_LDY
@ MOS65XX_INS_LDY
Definition: mos65xx.h:76
MOS65XX_INS_PLA
@ MOS65XX_INS_PLA
Definition: mos65xx.h:81
MOS65XX_INS_ROL
@ MOS65XX_INS_ROL
Definition: mos65xx.h:84
MOS65XX_INS_BVC
@ MOS65XX_INS_BVC
Definition: mos65xx.h:56
MOS65XX_REG_ACC
@ MOS65XX_REG_ACC
accumulator
Definition: mos65xx.h:16
MOS65XX_INS_JSR
@ MOS65XX_INS_JSR
Definition: mos65xx.h:73
MOS65XX_INS_PHA
@ MOS65XX_INS_PHA
Definition: mos65xx.h:80
MOS65XX_GRP_RET
@ MOS65XX_GRP_RET
= CS_GRP_RET
Definition: mos65xx.h:109
cs_mos65xx_op::type
mos65xx_op_type type
operand type
Definition: mos65xx.h:125
MOS65XX_AM_INDY
@ MOS65XX_AM_INDY
indirect indexed addressing by the Y index register
Definition: mos65xx.h:35
MOS65XX_OP_INVALID
@ MOS65XX_OP_INVALID
= CS_OP_INVALID (Uninitialized).
Definition: mos65xx.h:117
MOS65XX_INS_CLV
@ MOS65XX_INS_CLV
Definition: mos65xx.h:61
MOS65XX_INS_DEX
@ MOS65XX_INS_DEX
Definition: mos65xx.h:66
mos65xx_reg
mos65xx_reg
MOS65XX registers and special registers.
Definition: mos65xx.h:14
MOS65XX_AM_ACC
@ MOS65XX_AM_ACC
accumulator addressing
Definition: mos65xx.h:28
MOS65XX_AM_ABSY
@ MOS65XX_AM_ABSY
indexed absolute addressing by the Y index register
Definition: mos65xx.h:33


grpc
Author(s):
autogenerated on Fri May 16 2025 02:59:30