40 #define OPCODE_(a, b, c, d) 0x##a##b##c##d
41 #define OPCODE(a, b, c, d) OPCODE_(a, b, c, d)
50 #define ADDR(nib, addrmode) \
52 { .addr = { .start = nib, .bits = -1, .mode = addrmode } }, .is_param = false \
56 #define ADDRBITS(nib, addrmode, b) \
58 { .addr = { .start = nib, .bits = b, .mode = addrmode } }, .is_param = false \
62 #define PARAM(reg, addrmode) \
63 { { .param = { .param = { \
66 .mode = addrmode } }, \
72 #define NOPARAM ADDR(NIB0, SH_ADDR_INVALID)
struct sh_param_builder_t SHParamBuilder
struct sh_op_raw_t SHOpRaw
enum sh_scaling_t SHScaling
enum sh_addr_mode_t SHAddrMode
const char * str_mnem
string mnemonic
SHScaling scaling
scaling for the opcode
SHOpMnem mnemonic
enum mnemonic
SHParamBuilder param_builder[2]
param builders for the params
ut16 mask
mask for opcode to mask out param bits
ut8 start
start bit of the param (assuming little-endian)
SHAddrMode mode
addressing mode being used
st8 bits
bits to be read (-1, if you want this to be inferred from mode)
struct sh_param_builder_addr_t addr
bool is_param
whether a param was directly passed