Rizin
unix-like reverse engineering framework and cli tools
rz_reg.h File Reference
#include <rz_types.h>
#include <rz_list.h>
#include <rz_util/rz_hex.h>
#include <rz_util/rz_bitvector.h>
#include <rz_util/rz_assert.h>

Go to the source code of this file.

Classes

struct  RzRegProfileAlias
 
struct  RzRegProfileDef
 
struct  RzRegProfile
 
struct  rz_reg_item_t
 
struct  rz_reg_arena_t
 
struct  rz_reg_set_t
 
struct  rz_reg_t
 
struct  rz_reg_flags_t
 

Macros

#define RZ_REG_COND_EQ   0
 
#define RZ_REG_COND_NE   1
 
#define RZ_REG_COND_CF   2
 
#define RZ_REG_COND_CARRY   2
 
#define RZ_REG_COND_NEG   3
 
#define RZ_REG_COND_NEGATIVE   3
 
#define RZ_REG_COND_OF   4
 
#define RZ_REG_COND_OVERFLOW   4
 
#define RZ_REG_COND_HI   5
 
#define RZ_REG_COND_HE   6
 
#define RZ_REG_COND_LO   7
 
#define RZ_REG_COND_LOE   8
 
#define RZ_REG_COND_GE   9
 
#define RZ_REG_COND_GT   10
 
#define RZ_REG_COND_LT   11
 
#define RZ_REG_COND_LE   12
 
#define RZ_REG_COND_LAST   13
 

Typedefs

typedef struct rz_reg_item_t RzRegItem
 
typedef struct rz_reg_arena_t RzRegArena
 
typedef struct rz_reg_set_t RzRegSet
 
typedef struct rz_reg_t RzReg
 
typedef struct rz_reg_flags_t RzRegFlags
 

Enumerations

enum  RzRegisterType {
  RZ_REG_TYPE_GPR , RZ_REG_TYPE_DRX , RZ_REG_TYPE_FPU , RZ_REG_TYPE_MMX ,
  RZ_REG_TYPE_XMM , RZ_REG_TYPE_YMM , RZ_REG_TYPE_FLG , RZ_REG_TYPE_SEG ,
  RZ_REG_TYPE_SYS , RZ_REG_TYPE_SEC , RZ_REG_TYPE_VC , RZ_REG_TYPE_VCC ,
  RZ_REG_TYPE_CTR , RZ_REG_TYPE_LAST , RZ_REG_TYPE_ANY = -1
}
 
enum  RzRegisterId {
  RZ_REG_NAME_PC , RZ_REG_NAME_SP , RZ_REG_NAME_SR , RZ_REG_NAME_BP ,
  RZ_REG_NAME_LR , RZ_REG_NAME_A0 , RZ_REG_NAME_A1 , RZ_REG_NAME_A2 ,
  RZ_REG_NAME_A3 , RZ_REG_NAME_A4 , RZ_REG_NAME_A5 , RZ_REG_NAME_A6 ,
  RZ_REG_NAME_A7 , RZ_REG_NAME_A8 , RZ_REG_NAME_A9 , RZ_REG_NAME_R0 ,
  RZ_REG_NAME_R1 , RZ_REG_NAME_R2 , RZ_REG_NAME_R3 , RZ_REG_NAME_ZF ,
  RZ_REG_NAME_SF , RZ_REG_NAME_CF , RZ_REG_NAME_OF , RZ_REG_NAME_SN ,
  RZ_REG_NAME_LAST
}
 

Functions

 RZ_LIB_VERSION_HEADER (rz_reg)
 

Macro Definition Documentation

◆ RZ_REG_COND_CARRY

#define RZ_REG_COND_CARRY   2

Definition at line 78 of file rz_reg.h.

◆ RZ_REG_COND_CF

#define RZ_REG_COND_CF   2

Definition at line 77 of file rz_reg.h.

◆ RZ_REG_COND_EQ

#define RZ_REG_COND_EQ   0

Definition at line 75 of file rz_reg.h.

◆ RZ_REG_COND_GE

#define RZ_REG_COND_GE   9

Definition at line 89 of file rz_reg.h.

◆ RZ_REG_COND_GT

#define RZ_REG_COND_GT   10

Definition at line 90 of file rz_reg.h.

◆ RZ_REG_COND_HE

#define RZ_REG_COND_HE   6

Definition at line 85 of file rz_reg.h.

◆ RZ_REG_COND_HI

#define RZ_REG_COND_HI   5

Definition at line 84 of file rz_reg.h.

◆ RZ_REG_COND_LAST

#define RZ_REG_COND_LAST   13

Definition at line 93 of file rz_reg.h.

◆ RZ_REG_COND_LE

#define RZ_REG_COND_LE   12

Definition at line 92 of file rz_reg.h.

◆ RZ_REG_COND_LO

#define RZ_REG_COND_LO   7

Definition at line 86 of file rz_reg.h.

◆ RZ_REG_COND_LOE

#define RZ_REG_COND_LOE   8

Definition at line 87 of file rz_reg.h.

◆ RZ_REG_COND_LT

#define RZ_REG_COND_LT   11

Definition at line 91 of file rz_reg.h.

◆ RZ_REG_COND_NE

#define RZ_REG_COND_NE   1

Definition at line 76 of file rz_reg.h.

◆ RZ_REG_COND_NEG

#define RZ_REG_COND_NEG   3

Definition at line 79 of file rz_reg.h.

◆ RZ_REG_COND_NEGATIVE

#define RZ_REG_COND_NEGATIVE   3

Definition at line 80 of file rz_reg.h.

◆ RZ_REG_COND_OF

#define RZ_REG_COND_OF   4

Definition at line 81 of file rz_reg.h.

◆ RZ_REG_COND_OVERFLOW

#define RZ_REG_COND_OVERFLOW   4

Definition at line 82 of file rz_reg.h.

Typedef Documentation

◆ RzReg

typedef struct rz_reg_t RzReg

◆ RzRegArena

typedef struct rz_reg_arena_t RzRegArena

◆ RzRegFlags

typedef struct rz_reg_flags_t RzRegFlags

◆ RzRegItem

typedef struct rz_reg_item_t RzRegItem

◆ RzRegSet

typedef struct rz_reg_set_t RzRegSet

Enumeration Type Documentation

◆ RzRegisterId

Enumerator
RZ_REG_NAME_PC 
RZ_REG_NAME_SP 
RZ_REG_NAME_SR 
RZ_REG_NAME_BP 
RZ_REG_NAME_LR 
RZ_REG_NAME_A0 
RZ_REG_NAME_A1 
RZ_REG_NAME_A2 
RZ_REG_NAME_A3 
RZ_REG_NAME_A4 
RZ_REG_NAME_A5 
RZ_REG_NAME_A6 
RZ_REG_NAME_A7 
RZ_REG_NAME_A8 
RZ_REG_NAME_A9 
RZ_REG_NAME_R0 
RZ_REG_NAME_R1 
RZ_REG_NAME_R2 
RZ_REG_NAME_R3 
RZ_REG_NAME_ZF 
RZ_REG_NAME_SF 
RZ_REG_NAME_CF 
RZ_REG_NAME_OF 
RZ_REG_NAME_SN 
RZ_REG_NAME_LAST 

Definition at line 42 of file rz_reg.h.

42  {
43  RZ_REG_NAME_PC, // program counter
44  RZ_REG_NAME_SP, // stack pointer
45  RZ_REG_NAME_SR, // status register
46  RZ_REG_NAME_BP, // base pointer
47  RZ_REG_NAME_LR, // link register
48  /* args */
49  RZ_REG_NAME_A0, // arguments
59  /* retval */
60  RZ_REG_NAME_R0, // return registers
64  /* flags */
69  /* syscall number (orig_eax,rax,r0,x0) */
72 } RzRegisterId;
RzRegisterId
Definition: rz_reg.h:42
@ RZ_REG_NAME_SP
Definition: rz_reg.h:44
@ RZ_REG_NAME_A4
Definition: rz_reg.h:53
@ RZ_REG_NAME_SN
Definition: rz_reg.h:70
@ RZ_REG_NAME_A9
Definition: rz_reg.h:58
@ RZ_REG_NAME_A5
Definition: rz_reg.h:54
@ RZ_REG_NAME_A6
Definition: rz_reg.h:55
@ RZ_REG_NAME_A3
Definition: rz_reg.h:52
@ RZ_REG_NAME_A2
Definition: rz_reg.h:51
@ RZ_REG_NAME_BP
Definition: rz_reg.h:46
@ RZ_REG_NAME_ZF
Definition: rz_reg.h:65
@ RZ_REG_NAME_OF
Definition: rz_reg.h:68
@ RZ_REG_NAME_R2
Definition: rz_reg.h:62
@ RZ_REG_NAME_LAST
Definition: rz_reg.h:71
@ RZ_REG_NAME_PC
Definition: rz_reg.h:43
@ RZ_REG_NAME_R1
Definition: rz_reg.h:61
@ RZ_REG_NAME_A1
Definition: rz_reg.h:50
@ RZ_REG_NAME_CF
Definition: rz_reg.h:67
@ RZ_REG_NAME_SF
Definition: rz_reg.h:66
@ RZ_REG_NAME_A7
Definition: rz_reg.h:56
@ RZ_REG_NAME_SR
Definition: rz_reg.h:45
@ RZ_REG_NAME_LR
Definition: rz_reg.h:47
@ RZ_REG_NAME_A8
Definition: rz_reg.h:57
@ RZ_REG_NAME_A0
Definition: rz_reg.h:49
@ RZ_REG_NAME_R0
Definition: rz_reg.h:60
@ RZ_REG_NAME_R3
Definition: rz_reg.h:63

◆ RzRegisterType

Enumerator
RZ_REG_TYPE_GPR 
RZ_REG_TYPE_DRX 
RZ_REG_TYPE_FPU 
RZ_REG_TYPE_MMX 
RZ_REG_TYPE_XMM 
RZ_REG_TYPE_YMM 
RZ_REG_TYPE_FLG 
RZ_REG_TYPE_SEG 
RZ_REG_TYPE_SYS 
RZ_REG_TYPE_SEC 
RZ_REG_TYPE_VC 
RZ_REG_TYPE_VCC 
RZ_REG_TYPE_CTR 
RZ_REG_TYPE_LAST 
RZ_REG_TYPE_ANY 

Definition at line 20 of file rz_reg.h.

20  {
21  RZ_REG_TYPE_GPR, //< General purpose
23  RZ_REG_TYPE_FPU, //< Floating point
29  RZ_REG_TYPE_SYS, //< System
31  RZ_REG_TYPE_VC, //< Vector
32  RZ_REG_TYPE_VCC, //< Vector control
33  RZ_REG_TYPE_CTR, //< Control
35  RZ_REG_TYPE_ANY = -1
RzRegisterType
Definition: rz_reg.h:20
@ RZ_REG_TYPE_SEG
Definition: rz_reg.h:28
@ RZ_REG_TYPE_SYS
Definition: rz_reg.h:29
@ RZ_REG_TYPE_SEC
Definition: rz_reg.h:30
@ RZ_REG_TYPE_MMX
Definition: rz_reg.h:24
@ RZ_REG_TYPE_GPR
Definition: rz_reg.h:21
@ RZ_REG_TYPE_YMM
Definition: rz_reg.h:26
@ RZ_REG_TYPE_LAST
Definition: rz_reg.h:34
@ RZ_REG_TYPE_FLG
Definition: rz_reg.h:27
@ RZ_REG_TYPE_VC
Definition: rz_reg.h:31
@ RZ_REG_TYPE_VCC
Definition: rz_reg.h:32
@ RZ_REG_TYPE_ANY
Definition: rz_reg.h:35
@ RZ_REG_TYPE_FPU
Definition: rz_reg.h:23
@ RZ_REG_TYPE_DRX
Definition: rz_reg.h:22
@ RZ_REG_TYPE_CTR
Definition: rz_reg.h:33
@ RZ_REG_TYPE_XMM
Definition: rz_reg.h:25

Function Documentation

◆ RZ_LIB_VERSION_HEADER()

RZ_LIB_VERSION_HEADER ( rz_reg  )