Rizin
unix-like reverse engineering framework and cli tools
cs_priv.h File Reference
#include <capstone/capstone.h>
#include "MCInst.h"
#include "SStream.h"

Go to the source code of this file.

Classes

struct  ARM_ITStatus
 
struct  customized_mnem
 
struct  insn_mnem
 
struct  cs_struct
 

Macros

#define MAX_ARCH   CS_ARCH_MAX
 
#define MODE_IS_BIG_ENDIAN(mode)   (((mode) & CS_MODE_BIG_ENDIAN) != 0)
 
#define CS_ASSERT(expr)
 

Typedefs

typedef void(* Printer_t) (MCInst *MI, SStream *OS, void *info)
 
typedef void(* PostPrinter_t) (csh handle, cs_insn *, char *mnem, MCInst *mci)
 
typedef bool(* Disasm_t) (csh handle, const uint8_t *code, size_t code_len, MCInst *instr, uint16_t *size, uint64_t address, void *info)
 
typedef const char *(* GetName_t) (csh handle, unsigned int id)
 
typedef void(* GetID_t) (cs_struct *h, cs_insn *insn, unsigned int id)
 
typedef const char *(* GetRegisterName_t) (unsigned RegNo)
 
typedef void(* GetRegisterAccess_t) (const cs_insn *insn, cs_regs regs_read, uint8_t *regs_read_count, cs_regs regs_write, uint8_t *regs_write_count)
 
typedef struct ARM_ITStatus ARM_ITStatus
 

Variables

cs_malloc_t cs_mem_malloc
 
cs_calloc_t cs_mem_calloc
 
cs_realloc_t cs_mem_realloc
 
cs_free_t cs_mem_free
 
cs_vsnprintf_t cs_vsnprintf
 

Macro Definition Documentation

◆ CS_ASSERT

#define CS_ASSERT (   expr)

Definition at line 97 of file cs_priv.h.

◆ MAX_ARCH

#define MAX_ARCH   CS_ARCH_MAX

Definition at line 81 of file cs_priv.h.

◆ MODE_IS_BIG_ENDIAN

#define MODE_IS_BIG_ENDIAN (   mode)    (((mode) & CS_MODE_BIG_ENDIAN) != 0)

Definition at line 84 of file cs_priv.h.

Typedef Documentation

◆ ARM_ITStatus

typedef struct ARM_ITStatus ARM_ITStatus

◆ Disasm_t

typedef bool(* Disasm_t) (csh handle, const uint8_t *code, size_t code_len, MCInst *instr, uint16_t *size, uint64_t address, void *info)

Definition at line 21 of file cs_priv.h.

◆ GetID_t

typedef void(* GetID_t) (cs_struct *h, cs_insn *insn, unsigned int id)

Definition at line 25 of file cs_priv.h.

◆ GetName_t

typedef const char*(* GetName_t) (csh handle, unsigned int id)

Definition at line 23 of file cs_priv.h.

◆ GetRegisterAccess_t

typedef void(* GetRegisterAccess_t) (const cs_insn *insn, cs_regs regs_read, uint8_t *regs_read_count, cs_regs regs_write, uint8_t *regs_write_count)

Definition at line 31 of file cs_priv.h.

◆ GetRegisterName_t

typedef const char*(* GetRegisterName_t) (unsigned RegNo)

Definition at line 28 of file cs_priv.h.

◆ PostPrinter_t

typedef void(* PostPrinter_t) (csh handle, cs_insn *, char *mnem, MCInst *mci)

Definition at line 19 of file cs_priv.h.

◆ Printer_t

typedef void(* Printer_t) (MCInst *MI, SStream *OS, void *info)

Definition at line 15 of file cs_priv.h.

Variable Documentation

◆ cs_mem_calloc

cs_calloc_t cs_mem_calloc
extern

Definition at line 349 of file cs.c.

Referenced by cs_disasm(), cs_open(), cs_option(), and make_id2insn().

◆ cs_mem_free

cs_free_t cs_mem_free
extern

Definition at line 351 of file cs.c.

Referenced by cs_close(), cs_disasm(), cs_free(), cs_malloc(), cs_open(), and cs_option().

◆ cs_mem_malloc

cs_malloc_t cs_mem_malloc
extern

Definition at line 348 of file cs.c.

Referenced by cs_malloc(), cs_open(), cs_option(), and cs_strdup().

◆ cs_mem_realloc

cs_realloc_t cs_mem_realloc
extern

Definition at line 350 of file cs.c.

Referenced by cs_disasm(), cs_open(), and cs_option().

◆ cs_vsnprintf

cs_vsnprintf_t cs_vsnprintf
extern

Definition at line 352 of file cs.c.

Referenced by cs_open(), cs_option(), cs_snprintf(), and SStream_concat().