2024-02-23 15:09:37 +00:00
|
|
|
#define TARGET_SIZE_B 0x0
|
|
|
|
#define TARGET_SIZE_W 0x1
|
|
|
|
#define TARGET_SIZE_L 0x2
|
|
|
|
#define TARGET_SIZE_zext 1 << 2
|
|
|
|
|
|
|
|
#define ADDR_SIZE_B (0x0 << 3)
|
|
|
|
#define ADDR_SIZE_W (0x1 << 3)
|
|
|
|
#define ADDR_SIZE_L (0x2 << 3)
|
|
|
|
|
|
|
|
#define TARGET_SIZE(x) (x & 0x3)
|
|
|
|
#define TARGET_ZEXT(x) (x & 0x4)
|
|
|
|
#define ADDR_SIZE(x) (x >> 3)
|
|
|
|
|
|
|
|
#define FIT8(x) (((x) & ~((int)0xFF)) == 0)
|
|
|
|
#define FIT16(x) (((x) & ~((int)0xFFFF)) == 0)
|
|
|
|
|
2024-02-22 15:13:52 +00:00
|
|
|
void encode_imm(int opc, int sz, expr_t exp);
|
2024-02-23 15:09:37 +00:00
|
|
|
void encode_addr(expr_t exp, int sz);
|
2024-02-22 15:13:52 +00:00
|
|
|
void branch(register int opc,expr_t exp);
|