Rizin
unix-like reverse engineering framework and cli tools
op.c File Reference
#include <rz_analysis.h>
#include <rz_util.h>
#include <rz_list.h>

Go to the source code of this file.

Classes

struct  optype
 

Functions

RZ_API RzAnalysisOprz_analysis_op_new (void)
 
RZ_API RzListrz_analysis_op_list_new (void)
 
RZ_API void rz_analysis_op_init (RzAnalysisOp *op)
 
RZ_API bool rz_analysis_op_fini (RzAnalysisOp *op)
 
RZ_API void rz_analysis_op_free (void *op)
 
static int defaultCycles (RzAnalysisOp *op)
 
RZ_API int rz_analysis_op (RzAnalysis *analysis, RzAnalysisOp *op, ut64 addr, const ut8 *data, int len, RzAnalysisOpMask mask)
 
RZ_API RzAnalysisOprz_analysis_op_copy (RzAnalysisOp *op)
 
RZ_API bool rz_analysis_op_nonlinear (int t)
 
RZ_API bool rz_analysis_op_ismemref (int t)
 
RZ_API int rz_analysis_optype_from_string (RZ_NONNULL const char *name)
 
RZ_API const char * rz_analysis_optype_to_string (int type)
 
RZ_API const char * rz_analysis_op_to_esil_string (RzAnalysis *analysis, RzAnalysisOp *op)
 
RZ_API char * rz_analysis_op_to_string (RzAnalysis *analysis, RzAnalysisOp *op)
 
RZ_API const char * rz_analysis_stackop_tostring (int s)
 
RZ_API const char * rz_analysis_op_family_to_string (int id)
 
RZ_API int rz_analysis_op_family_from_string (RZ_NONNULL const char *name)
 
RZ_API int rz_analysis_op_hint (RzAnalysisOp *op, RzAnalysisHint *hint)
 
RZ_API int rz_analysis_op_reg_delta (RzAnalysis *analysis, ut64 addr, const char *name)
 

Variables

static struct optype optypes []
 
struct {
   int   id
 
   const char *   name
 
op_families []
 

Function Documentation

◆ defaultCycles()

static int defaultCycles ( RzAnalysisOp op)
static

Definition at line 70 of file op.c.

70  {
71  switch (op->type) {
76  return 2;
80  return 1;
83  return 4;
85  return 4;
90  return 4;
91  default:
92  return 1;
93  }
94 }
@ RZ_ANALYSIS_OP_TYPE_LOAD
Definition: rz_analysis.h:416
@ RZ_ANALYSIS_OP_TYPE_JMP
Definition: rz_analysis.h:368
@ RZ_ANALYSIS_OP_TYPE_SYNC
Definition: rz_analysis.h:431
@ RZ_ANALYSIS_OP_TYPE_SWI
Definition: rz_analysis.h:393
@ RZ_ANALYSIS_OP_TYPE_TRAP
Definition: rz_analysis.h:392
@ RZ_ANALYSIS_OP_TYPE_CALL
Definition: rz_analysis.h:378
@ RZ_ANALYSIS_OP_TYPE_STORE
Definition: rz_analysis.h:415
@ RZ_ANALYSIS_OP_TYPE_PUSH
Definition: rz_analysis.h:397
@ RZ_ANALYSIS_OP_TYPE_POP
Definition: rz_analysis.h:398
@ RZ_ANALYSIS_OP_TYPE_RJMP
Definition: rz_analysis.h:370
@ RZ_ANALYSIS_OP_TYPE_MOV
Definition: rz_analysis.h:390
@ RZ_ANALYSIS_OP_TYPE_RET
Definition: rz_analysis.h:385
@ RZ_ANALYSIS_OP_TYPE_NOP
Definition: rz_analysis.h:389
@ RZ_ANALYSIS_OP_TYPE_LEA
Definition: rz_analysis.h:417
Definition: dis.c:32

References RZ_ANALYSIS_OP_TYPE_CALL, RZ_ANALYSIS_OP_TYPE_JMP, RZ_ANALYSIS_OP_TYPE_LEA, RZ_ANALYSIS_OP_TYPE_LOAD, RZ_ANALYSIS_OP_TYPE_MOV, RZ_ANALYSIS_OP_TYPE_NOP, RZ_ANALYSIS_OP_TYPE_POP, RZ_ANALYSIS_OP_TYPE_PUSH, RZ_ANALYSIS_OP_TYPE_RET, RZ_ANALYSIS_OP_TYPE_RJMP, RZ_ANALYSIS_OP_TYPE_STORE, RZ_ANALYSIS_OP_TYPE_SWI, RZ_ANALYSIS_OP_TYPE_SYNC, and RZ_ANALYSIS_OP_TYPE_TRAP.

Referenced by rz_analysis_op().

◆ rz_analysis_op()

RZ_API int rz_analysis_op ( RzAnalysis analysis,
RzAnalysisOp op,
ut64  addr,
const ut8 data,
int  len,
RzAnalysisOpMask  mask 
)

Definition at line 96 of file op.c.

96  {
98  rz_return_val_if_fail(analysis && op && len > 0, -1);
99 
100  int ret = RZ_MIN(2, len);
101  if (len > 0 && analysis->cur && analysis->cur->op) {
102  // use core binding to set asm.bits correctly based on the addr
103  // this is because of the hassle of arm/thumb
104  if (analysis && analysis->coreb.archbits) {
105  analysis->coreb.archbits(analysis->coreb.core, addr);
106  }
107  if (analysis->pcalign && addr % analysis->pcalign) {
108  op->type = RZ_ANALYSIS_OP_TYPE_ILL;
109  op->addr = addr;
110  // RZ_LOG_DEBUG("Unaligned instruction for %d bits at 0x%"PFMT64x"\n", analysis->bits, addr);
111  op->size = 1;
112  return -1;
113  }
114  ret = analysis->cur->op(analysis, op, addr, data, len, mask);
115  if (ret < 1) {
116  op->type = RZ_ANALYSIS_OP_TYPE_ILL;
117  }
118  op->addr = addr;
119  /* consider at least 1 byte to be part of the opcode */
120  if (op->nopcode < 1) {
121  op->nopcode = 1;
122  }
123  } else if (!memcmp(data, "\xff\xff\xff\xff", RZ_MIN(4, len))) {
124  op->type = RZ_ANALYSIS_OP_TYPE_ILL;
125  } else {
126  op->type = RZ_ANALYSIS_OP_TYPE_MOV;
127  if (op->cycles == 0) {
128  op->cycles = defaultCycles(op);
129  }
130  }
131  if (!op->mnemonic && (mask & RZ_ANALYSIS_OP_MASK_DISASM)) {
132  RZ_LOG_DEBUG("Warning: unhandled RZ_ANALYSIS_OP_MASK_DISASM in rz_analysis_op\n");
133  }
135  RzAnalysisHint *hint = rz_analysis_hint_get(analysis, addr);
136  if (hint) {
137  rz_analysis_op_hint(op, hint);
138  rz_analysis_hint_free(hint);
139  }
140  }
141  return ret;
142 }
size_t len
Definition: 6502dis.c:15
#define mask()
RZ_API RzAnalysisHint * rz_analysis_hint_get(RzAnalysis *a, ut64 addr)
Definition: hint.c:506
RZ_API void rz_analysis_hint_free(RzAnalysisHint *h)
Definition: hint.c:371
RZ_API int rz_analysis_op_hint(RzAnalysisOp *op, RzAnalysisHint *hint)
Definition: op.c:588
static int defaultCycles(RzAnalysisOp *op)
Definition: op.c:70
RZ_API void rz_analysis_op_init(RzAnalysisOp *op)
Definition: op.c:23
@ RZ_ANALYSIS_OP_MASK_DISASM
Definition: rz_analysis.h:445
@ RZ_ANALYSIS_OP_MASK_HINT
Definition: rz_analysis.h:443
@ RZ_ANALYSIS_OP_TYPE_ILL
Definition: rz_analysis.h:387
#define rz_return_val_if_fail(expr, val)
Definition: rz_assert.h:108
#define RZ_LOG_DEBUG(fmtstr,...)
Definition: rz_log.h:49
#define RZ_MIN(x, y)
RzAnalysisOpCallback op
Definition: rz_analysis.h:1257
struct rz_analysis_plugin_t * cur
Definition: rz_analysis.h:586
RzCoreBind coreb
Definition: rz_analysis.h:580
void * core
Definition: rz_bind.h:31
RzCoreSeekArchBits archbits
Definition: rz_bind.h:42
static int addr
Definition: z80asm.c:58

References addr, rz_core_bind_t::archbits, rz_core_bind_t::core, rz_analysis_t::coreb, rz_analysis_t::cur, defaultCycles(), len, mask, rz_analysis_plugin_t::op, rz_analysis_t::pcalign, rz_analysis_hint_free(), rz_analysis_hint_get(), rz_analysis_op_hint(), rz_analysis_op_init(), RZ_ANALYSIS_OP_MASK_DISASM, RZ_ANALYSIS_OP_MASK_HINT, RZ_ANALYSIS_OP_TYPE_ILL, RZ_ANALYSIS_OP_TYPE_MOV, RZ_LOG_DEBUG, RZ_MIN, and rz_return_val_if_fail.

Referenced by __analysis_esil_function(), __analysis_fcn_check_bp_use(), __core_cmd_search_asm_infinite(), __esil_step(), _analysis_calls(), bbget(), cmd_aea(), cmd_analysis_esil(), cmd_debug_backtrace(), cmd_print_pxA(), construct_rop_gadget(), core_analysis_bytes_desc(), core_analysis_bytes_esil(), core_analysis_bytes_size(), decode_auipc_set_addr(), decode_disp_set_addr(), decode_ldr_set_addr(), decode_lui_set_addr(), decode_one_opcode_size(), decode_ptr_set_addr(), decode_val_add_addr(), decode_val_set_addr(), decode_val_set_size(), do_analysis_search(), do_debug_trace_calls(), do_syscall_search(), ds_show_refs(), get_calls(), getpcfromstack(), is_delta_pointer_table(), iscallret(), noreturn_recurse(), num_callback(), opiscall(), prevop_addr(), print_cmd_analysis_after_traps_print(), print_rop(), process_reference_noreturn_cb(), rasm_disasm(), run_basic_block_analysis(), rz_analysis_block_analyze_ops(), rz_analysis_check_fcn(), rz_analysis_diff_fingerprint_bb(), rz_analysis_function_cost(), rz_analysis_get_delta_jmptbl_info(), rz_analysis_get_jmptbl_info(), rz_analysis_il_vm_step(), rz_analysis_mask(), rz_analysis_op_hexstr(), rz_analysis_op_reg_delta(), rz_analysis_reflines_get(), rz_analysis_xrefs_from_list_handler(), rz_cmd_debug_step_prog_handler(), rz_cmd_disassemble_recursively_no_function_handler(), rz_cmd_disassembly_all_possible_opcodes_handler(), rz_cmd_disassembly_all_possible_opcodes_treeview_handler(), rz_core_analysis_bytes(), rz_core_analysis_esil(), rz_core_analysis_esil_emulate(), rz_core_analysis_hint_set_offset(), rz_core_analysis_name(), rz_core_analysis_op(), rz_core_analysis_rename(), rz_core_analysis_search(), rz_core_analysis_search_xrefs(), rz_core_asm_strsearch(), rz_core_debug_step_skip(), rz_core_disasm_instruction(), rz_core_disasm_pde(), rz_core_disasm_pdi_with_buf(), rz_core_esil_of_assembly(), rz_core_esil_of_hex(), rz_core_esil_step(), rz_core_hack(), rz_core_link_stroff(), rz_core_op_analysis(), rz_core_print_disasm(), rz_core_print_disasm_all(), rz_core_print_disasm_instructions_with_buf(), rz_core_search_rop(), rz_core_seek_next(), rz_core_seek_opcode_forward(), rz_core_visual_bit_editor(), rz_core_visual_define(), rz_core_visual_esil(), rz_core_write_assembly_fill(), rz_debug_continue_kill(), rz_debug_continue_until_optype(), rz_debug_esil_stepi(), rz_debug_step_over(), rz_debug_step_soft(), rz_debug_trace_ins_before(), rz_debug_trace_pc(), show_analinfo(), step_until_optype(), update_varz_analysisysis(), and vtable_is_addr_vtable_start_msvc().

◆ rz_analysis_op_copy()

RZ_API RzAnalysisOp* rz_analysis_op_copy ( RzAnalysisOp op)

Definition at line 144 of file op.c.

144  {
146  if (!nop) {
147  return NULL;
148  }
149  *nop = *op;
150  if (op->mnemonic) {
151  nop->mnemonic = strdup(op->mnemonic);
152  if (!nop->mnemonic) {
153  free(nop);
154  return NULL;
155  }
156  } else {
157  nop->mnemonic = NULL;
158  }
159  nop->src[0] = rz_analysis_value_copy(op->src[0]);
160  nop->src[1] = rz_analysis_value_copy(op->src[1]);
161  nop->src[2] = rz_analysis_value_copy(op->src[2]);
162  nop->dst = rz_analysis_value_copy(op->dst);
163  if (op->access) {
164  RzListIter *it;
167  rz_list_foreach (op->access, it, val) {
169  }
170  nop->access = naccess;
171  }
172  rz_strbuf_init(&nop->esil);
173  rz_strbuf_copy(&nop->esil, &op->esil);
174  return nop;
175 }
ut8 op
Definition: 6502dis.c:13
RZ_API void rz_analysis_value_free(RzAnalysisValue *value)
Definition: value.c:29
RZ_API RzAnalysisValue * rz_analysis_value_copy(RzAnalysisValue *ov)
Definition: value.c:15
ut16 val
Definition: armass64_const.h:6
#define NULL
Definition: cris-opc.c:27
RZ_API void Ht_() free(HtName_(Ht) *ht)
Definition: ht_inc.c:130
RZ_API RZ_OWN RzList * rz_list_newf(RzListFree f)
Returns a new initialized RzList pointer and sets the free method.
Definition: list.c:248
RZ_API RZ_BORROW RzListIter * rz_list_append(RZ_NONNULL RzList *list, void *data)
Appends at the end of the list a new element.
Definition: list.c:288
return strdup("=SP r13\n" "=LR r14\n" "=PC r15\n" "=A0 r0\n" "=A1 r1\n" "=A2 r2\n" "=A3 r3\n" "=ZF zf\n" "=SF nf\n" "=OF vf\n" "=CF cf\n" "=SN or0\n" "gpr lr .32 56 0\n" "gpr pc .32 60 0\n" "gpr cpsr .32 64 0 ____tfiae_________________qvczn\n" "gpr or0 .32 68 0\n" "gpr tf .1 64.5 0 thumb\n" "gpr ef .1 64.9 0 endian\n" "gpr jf .1 64.24 0 java\n" "gpr qf .1 64.27 0 sticky_overflow\n" "gpr vf .1 64.28 0 overflow\n" "gpr cf .1 64.29 0 carry\n" "gpr zf .1 64.30 0 zero\n" "gpr nf .1 64.31 0 negative\n" "gpr itc .4 64.10 0 if_then_count\n" "gpr gef .4 64.16 0 great_or_equal\n" "gpr r0 .32 0 0\n" "gpr r1 .32 4 0\n" "gpr r2 .32 8 0\n" "gpr r3 .32 12 0\n" "gpr r4 .32 16 0\n" "gpr r5 .32 20 0\n" "gpr r6 .32 24 0\n" "gpr r7 .32 28 0\n" "gpr r8 .32 32 0\n" "gpr r9 .32 36 0\n" "gpr r10 .32 40 0\n" "gpr r11 .32 44 0\n" "gpr r12 .32 48 0\n" "gpr r13 .32 52 0\n" "gpr r14 .32 56 0\n" "gpr r15 .32 60 0\n" "gpr r16 .32 64 0\n" "gpr r17 .32 68 0\n")
void(* RzListFree)(void *ptr)
Definition: rz_list.h:11
RZ_API bool rz_strbuf_copy(RzStrBuf *dst, RzStrBuf *src)
Definition: strbuf.c:48
RZ_API void rz_strbuf_init(RzStrBuf *sb)
Definition: strbuf.c:33
#define RZ_NEW0(x)
Definition: rz_types.h:284
RzAnalysisValue * dst
Definition: rz_analysis.h:840
RzAnalysisValue * src[3]
Definition: rz_analysis.h:839

References rz_analysis_op_t::access, rz_analysis_op_t::dst, rz_analysis_op_t::esil, free(), rz_analysis_op_t::mnemonic, NULL, op, rz_analysis_value_copy(), rz_analysis_value_free(), rz_list_append(), rz_list_newf(), RZ_NEW0, rz_strbuf_copy(), rz_strbuf_init(), rz_analysis_op_t::src, strdup(), and val.

◆ rz_analysis_op_family_from_string()

RZ_API int rz_analysis_op_family_from_string ( RZ_NONNULL const char *  name)

Return the op family id given its name

Parameters
namestring, name of the op family
Returns
id int, id of the operation family (one of RzAnalysisOpFamily)

Definition at line 576 of file op.c.

576  {
577  int i;
579  for (i = 0; i < RZ_ARRAY_SIZE(op_families); i++) {
580  if (!strcmp(name, op_families[i].name)) {
581  return op_families[i].id;
582  }
583  }
585 }
lzma_index ** i
Definition: index.h:629
static const struct @7 op_families[]
@ RZ_ANALYSIS_OP_FAMILY_UNKNOWN
Definition: rz_analysis.h:311
#define RZ_ARRAY_SIZE(x)
Definition: rz_types.h:300
Definition: z80asm.h:102

References i, op_families, RZ_ANALYSIS_OP_FAMILY_UNKNOWN, RZ_ARRAY_SIZE, and rz_return_val_if_fail.

◆ rz_analysis_op_family_to_string()

RZ_API const char* rz_analysis_op_family_to_string ( int  id)

Return the name of the given op family

Parameters
idint, id of the operation family (one of RzAnalysisOpFamily)
Returns
name string, name of the op family

Definition at line 560 of file op.c.

560  {
561  int i;
562 
563  for (i = 0; i < RZ_ARRAY_SIZE(op_families); i++) {
564  if (op_families[i].id == id) {
565  return op_families[i].name;
566  }
567  }
568  return NULL;
569 }

References i, NULL, op_families, and RZ_ARRAY_SIZE.

Referenced by core_analysis_bytes_json(), core_analysis_bytes_standard(), do_analysis_search(), ds_print_family(), rz_core_print_disasm_json(), and update_stat_for_op().

◆ rz_analysis_op_fini()

RZ_API bool rz_analysis_op_fini ( RzAnalysisOp op)

Definition at line 37 of file op.c.

37  {
38  if (!op) {
39  return false;
40  }
41  rz_analysis_value_free(op->src[0]);
42  rz_analysis_value_free(op->src[1]);
43  rz_analysis_value_free(op->src[2]);
44  op->src[0] = NULL;
45  op->src[1] = NULL;
46  op->src[2] = NULL;
48  op->dst = NULL;
49  rz_list_free(op->access);
50  op->access = NULL;
51  rz_strbuf_fini(&op->opex);
52  rz_strbuf_fini(&op->esil);
53  rz_analysis_switch_op_free(op->switch_op);
54  op->switch_op = NULL;
55  RZ_FREE(op->mnemonic);
56  rz_il_op_effect_free(op->il_op);
57  op->il_op = NULL;
58  return true;
59 }
RZ_API void rz_il_op_effect_free(RZ_NULLABLE RzILOpEffect *op)
Definition: il_opcodes.c:1036
RZ_API void rz_list_free(RZ_NONNULL RzList *list)
Empties the list and frees the list pointer.
Definition: list.c:137
RZ_API void rz_strbuf_fini(RzStrBuf *sb)
Definition: strbuf.c:365
#define RZ_FREE(x)
Definition: rz_types.h:369
RZ_API void rz_analysis_switch_op_free(RzAnalysisSwitchOp *swop)
Definition: switch.c:42

References NULL, rz_analysis_switch_op_free(), rz_analysis_value_free(), RZ_FREE, rz_il_op_effect_free(), rz_list_free(), and rz_strbuf_fini().

Referenced by __analysis_esil_function(), __analysis_fcn_check_bp_use(), __core_cmd_search_asm_infinite(), __esil_step(), _analysis_calls(), bbget(), cmd_aea(), cmd_analysis_esil(), cmd_print_pxA(), construct_rop_gadget(), core_analysis_bytes_desc(), core_analysis_bytes_esil(), core_analysis_bytes_size(), decode_auipc_set_addr(), decode_disp_set_addr(), decode_ldr_set_addr(), decode_lui_set_addr(), decode_one_opcode_size(), decode_ptr_set_addr(), decode_val_add_addr(), decode_val_set_addr(), decode_val_set_size(), do_syscall_search(), ds_free(), get_calls(), getpcfromstack(), is_delta_pointer_table(), num_callback(), prevop_addr(), print_cmd_analysis_after_traps_print(), print_rop(), process_reference_noreturn_cb(), rasm_disasm(), run_basic_block_analysis(), rz_analysis_block_analyze_ops(), rz_analysis_check_fcn(), rz_analysis_function_cost(), rz_analysis_get_delta_jmptbl_info(), rz_analysis_get_jmptbl_info(), rz_analysis_il_vm_step(), rz_analysis_mask(), rz_analysis_op_free(), rz_analysis_op_reg_delta(), rz_analysis_reflines_get(), rz_cmd_disassemble_recursively_no_function_handler(), rz_core_analysis_esil(), rz_core_analysis_esil_emulate(), rz_core_analysis_hint_set_offset(), rz_core_analysis_name(), rz_core_analysis_rename(), rz_core_analysis_search(), rz_core_analysis_search_xrefs(), rz_core_asm_strsearch(), rz_core_disasm_instruction(), rz_core_disasm_pde(), rz_core_disasm_pdi_with_buf(), rz_core_esil_of_assembly(), rz_core_esil_of_hex(), rz_core_esil_step(), rz_core_link_stroff(), rz_core_print_disasm(), rz_core_print_disasm_instructions_with_buf(), rz_core_print_func_args(), rz_core_search_rop(), rz_core_seek_opcode_forward(), rz_core_visual_bit_editor(), rz_core_visual_define(), rz_core_visual_esil(), rz_debug_trace_pc(), show_analinfo(), update_varz_analysisysis(), and vtable_is_addr_vtable_start_msvc().

◆ rz_analysis_op_free()

◆ rz_analysis_op_hint()

RZ_API int rz_analysis_op_hint ( RzAnalysisOp op,
RzAnalysisHint hint 
)

Definition at line 588 of file op.c.

588  {
589  int changes = 0;
590  if (hint) {
591  if (hint->val != UT64_MAX) {
592  op->val = hint->val;
593  changes++;
594  }
595  if (hint->type > 0) {
596  op->type = hint->type;
597  changes++;
598  }
599  if (hint->jump != UT64_MAX) {
600  op->jump = hint->jump;
601  changes++;
602  }
603  if (hint->fail != UT64_MAX) {
604  op->fail = hint->fail;
605  changes++;
606  }
607  if (hint->opcode) {
608  /* XXX: this is not correct */
609  free(op->mnemonic);
610  op->mnemonic = strdup(hint->opcode);
611  changes++;
612  }
613  if (hint->esil) {
614  rz_strbuf_set(&op->esil, hint->esil);
615  changes++;
616  }
617  if (hint->size) {
618  op->size = hint->size;
619  changes++;
620  }
621  }
622  return changes;
623 }
RZ_API const char * rz_strbuf_set(RzStrBuf *sb, const char *s)
Definition: strbuf.c:153
#define UT64_MAX
Definition: rz_types_base.h:86

References rz_analysis_hint_t::esil, rz_analysis_hint_t::fail, free(), rz_analysis_hint_t::jump, rz_analysis_hint_t::opcode, rz_strbuf_set(), rz_analysis_hint_t::size, strdup(), rz_analysis_hint_t::type, UT64_MAX, and rz_analysis_hint_t::val.

Referenced by rz_analysis_op().

◆ rz_analysis_op_init()

RZ_API void rz_analysis_op_init ( RzAnalysisOp op)

Definition at line 23 of file op.c.

23  {
24  if (op) {
25  memset(op, 0, sizeof(*op));
26  op->addr = UT64_MAX;
27  op->jump = UT64_MAX;
28  op->fail = UT64_MAX;
29  op->ptr = UT64_MAX;
30  op->refptr = 0;
31  op->val = UT64_MAX;
32  op->disp = UT64_MAX;
33  op->mmio_address = UT64_MAX;
34  }
35 }

References memset(), and UT64_MAX.

Referenced by decode_auipc_set_addr(), decode_disp_set_addr(), decode_ldr_set_addr(), decode_lui_set_addr(), decode_one_opcode_size(), decode_ptr_set_addr(), decode_val_add_addr(), decode_val_set_addr(), decode_val_set_size(), rz_analysis_mask(), rz_analysis_op(), rz_analysis_op_new(), rz_analysis_op_reg_delta(), and rz_cmd_disassemble_recursively_no_function_handler().

◆ rz_analysis_op_ismemref()

RZ_API bool rz_analysis_op_ismemref ( int  t)

Definition at line 208 of file op.c.

208  {
210  switch (t) {
216  return true;
217  default:
218  return false;
219  }
220 }
#define RZ_ANALYSIS_OP_TYPE_MASK
Definition: rz_analysis.h:358
@ RZ_ANALYSIS_OP_TYPE_CMP
Definition: rz_analysis.h:399

References RZ_ANALYSIS_OP_TYPE_CMP, RZ_ANALYSIS_OP_TYPE_LEA, RZ_ANALYSIS_OP_TYPE_LOAD, RZ_ANALYSIS_OP_TYPE_MASK, RZ_ANALYSIS_OP_TYPE_MOV, and RZ_ANALYSIS_OP_TYPE_STORE.

Referenced by set_offset_hint().

◆ rz_analysis_op_list_new()

RZ_API RzList* rz_analysis_op_list_new ( void  )

Definition at line 15 of file op.c.

15  {
16  RzList *list = rz_list_new();
17  if (list) {
18  list->free = &rz_analysis_op_free;
19  }
20  return list;
21 }
static void list(RzEgg *egg)
Definition: rz-gg.c:52
RZ_API RZ_OWN RzList * rz_list_new(void)
Returns a new initialized RzList pointer (free method is not initialized)
Definition: list.c:235
RZ_API void rz_analysis_op_free(void *op)
Definition: op.c:61

References list(), rz_analysis_op_free(), and rz_list_new().

◆ rz_analysis_op_new()

RZ_API RzAnalysisOp* rz_analysis_op_new ( void  )

Definition at line 9 of file op.c.

9  {
12  return op;
13 }
#define RZ_NEW(x)
Definition: rz_types.h:285

References op, rz_analysis_op_init(), and RZ_NEW.

Referenced by analysis_mask(), rz_analysis_diff_fingerprint_bb(), rz_analysis_mask(), and rz_core_analysis_bytes().

◆ rz_analysis_op_nonlinear()

RZ_API bool rz_analysis_op_nonlinear ( int  t)

Definition at line 177 of file op.c.

177  {
179  switch (t) {
180  // call
187  // jmp
196  // trap| ill| unk
202  return true;
203  default:
204  return false;
205  }
206 }
@ RZ_ANALYSIS_OP_TYPE_ICALL
Definition: rz_analysis.h:381
@ RZ_ANALYSIS_OP_TYPE_UNK
Definition: rz_analysis.h:388
@ RZ_ANALYSIS_OP_TYPE_UJMP
Definition: rz_analysis.h:369
@ RZ_ANALYSIS_OP_TYPE_IJMP
Definition: rz_analysis.h:371
@ RZ_ANALYSIS_OP_TYPE_UCCALL
Definition: rz_analysis.h:384
@ RZ_ANALYSIS_OP_TYPE_MJMP
Definition: rz_analysis.h:375
@ RZ_ANALYSIS_OP_TYPE_IRJMP
Definition: rz_analysis.h:372
@ RZ_ANALYSIS_OP_TYPE_CJMP
Definition: rz_analysis.h:373
@ RZ_ANALYSIS_OP_TYPE_UCJMP
Definition: rz_analysis.h:377
@ RZ_ANALYSIS_OP_TYPE_UCALL
Definition: rz_analysis.h:379
@ RZ_ANALYSIS_OP_TYPE_RCALL
Definition: rz_analysis.h:380
@ RZ_ANALYSIS_OP_TYPE_IRCALL
Definition: rz_analysis.h:382

References RZ_ANALYSIS_OP_TYPE_CALL, RZ_ANALYSIS_OP_TYPE_CJMP, RZ_ANALYSIS_OP_TYPE_ICALL, RZ_ANALYSIS_OP_TYPE_IJMP, RZ_ANALYSIS_OP_TYPE_ILL, RZ_ANALYSIS_OP_TYPE_IRCALL, RZ_ANALYSIS_OP_TYPE_IRJMP, RZ_ANALYSIS_OP_TYPE_JMP, RZ_ANALYSIS_OP_TYPE_MASK, RZ_ANALYSIS_OP_TYPE_MJMP, RZ_ANALYSIS_OP_TYPE_RCALL, RZ_ANALYSIS_OP_TYPE_RET, RZ_ANALYSIS_OP_TYPE_RJMP, RZ_ANALYSIS_OP_TYPE_SWI, RZ_ANALYSIS_OP_TYPE_TRAP, RZ_ANALYSIS_OP_TYPE_UCALL, RZ_ANALYSIS_OP_TYPE_UCCALL, RZ_ANALYSIS_OP_TYPE_UCJMP, RZ_ANALYSIS_OP_TYPE_UJMP, and RZ_ANALYSIS_OP_TYPE_UNK.

Referenced by rz_core_analysis_type_match(), and rz_core_link_stroff().

◆ rz_analysis_op_reg_delta()

RZ_API int rz_analysis_op_reg_delta ( RzAnalysis analysis,
ut64  addr,
const char *  name 
)

Definition at line 627 of file op.c.

627  {
628  int delta = 0;
629  ut8 buf[32];
630  analysis->iob.read_at(analysis->iob.io, addr, buf, sizeof(buf));
633  if (rz_analysis_op(analysis, &op, addr, buf, sizeof(buf), RZ_ANALYSIS_OP_MASK_ALL) > 0) {
634  if (op.dst && op.dst->reg && op.dst->reg->name && (!name || !strcmp(op.dst->reg->name, name))) {
635  if (op.src[0]) {
636  delta = op.src[0]->delta;
637  }
638  }
639  }
641  return delta;
642 }
voidpf void * buf
Definition: ioapi.h:138
uint8_t ut8
Definition: lh5801.h:11
RZ_API int rz_analysis_op(RzAnalysis *analysis, RzAnalysisOp *op, ut64 addr, const ut8 *data, int len, RzAnalysisOpMask mask)
Definition: op.c:96
@ RZ_ANALYSIS_OP_MASK_ALL
Definition: rz_analysis.h:447
RzIOBind iob
Definition: rz_analysis.h:574
RzIOReadAt read_at
Definition: rz_io.h:240
RzIO * io
Definition: rz_io.h:232
static st64 delta
Definition: vmenus.c:2425

References addr, delta, rz_io_bind_t::io, rz_analysis_t::iob, op, rz_io_bind_t::read_at, rz_analysis_op(), rz_analysis_op_fini(), rz_analysis_op_init(), and RZ_ANALYSIS_OP_MASK_ALL.

◆ rz_analysis_op_to_esil_string()

RZ_API const char* rz_analysis_op_to_esil_string ( RzAnalysis analysis,
RzAnalysisOp op 
)

Definition at line 329 of file op.c.

329  {
330  return rz_strbuf_get(&op->esil);
331 }
RZ_API char * rz_strbuf_get(RzStrBuf *sb)
Definition: strbuf.c:321

References rz_strbuf_get().

◆ rz_analysis_op_to_string()

RZ_API char* rz_analysis_op_to_string ( RzAnalysis analysis,
RzAnalysisOp op 
)

Definition at line 334 of file op.c.

334  {
335  RzAnalysisBlock *bb;
337  char *cstr, ret[128];
338  char *r0 = rz_analysis_value_to_string(op->dst);
339  char *a0 = rz_analysis_value_to_string(op->src[0]);
340  char *a1 = rz_analysis_value_to_string(op->src[1]);
341  if (!r0) {
342  r0 = strdup("?");
343  }
344  if (!a0) {
345  a0 = strdup("?");
346  }
347  if (!a1) {
348  a1 = strdup("?");
349  }
350 
351  switch (op->type) {
353  snprintf(ret, sizeof(ret), "%s = %s", r0, a0);
354  break;
356  if ((bb = rz_analysis_find_most_relevant_block_in(analysis, op->addr))) {
357  cstr = rz_analysis_cond_to_string(bb->cond);
358  snprintf(ret, sizeof(ret), "if (%s) goto 0x%" PFMT64x, cstr, op->jump);
359  free(cstr);
360  } else {
361  snprintf(ret, sizeof(ret), "if (%s) goto 0x%" PFMT64x, "?", op->jump);
362  }
363  break;
365  snprintf(ret, sizeof(ret), "goto 0x%" PFMT64x, op->jump);
366  break;
371  snprintf(ret, sizeof(ret), "goto %s", r0);
372  break;
376  snprintf(ret, sizeof(ret), "push %s", a0);
377  break;
379  snprintf(ret, sizeof(ret), "pop %s", r0);
380  break;
385  snprintf(ret, sizeof(ret), "%s()", r0);
386  break;
389  if (f) {
390  snprintf(ret, sizeof(ret), "%s()", f->name);
391  } else {
392  snprintf(ret, sizeof(ret), "0x%" PFMT64x "()", op->jump);
393  }
394  break;
397  if ((bb = rz_analysis_find_most_relevant_block_in(analysis, op->addr))) {
398  cstr = rz_analysis_cond_to_string(bb->cond);
399  if (f) {
400  snprintf(ret, sizeof(ret), "if (%s) %s()", cstr, f->name);
401  } else {
402  snprintf(ret, sizeof(ret), "if (%s) 0x%" PFMT64x "()", cstr, op->jump);
403  }
404  free(cstr);
405  } else {
406  if (f) {
407  snprintf(ret, sizeof(ret), "if (unk) %s()", f->name);
408  } else {
409  snprintf(ret, sizeof(ret), "if (unk) 0x%" PFMT64x "()", op->jump);
410  }
411  }
412  break;
414  if (!a1 || !strcmp(a0, a1)) {
415  snprintf(ret, sizeof(ret), "%s += %s", r0, a0);
416  } else {
417  snprintf(ret, sizeof(ret), "%s = %s + %s", r0, a0, a1);
418  }
419  break;
421  if (!a1 || !strcmp(a0, a1)) {
422  snprintf(ret, sizeof(ret), "%s -= %s", r0, a0);
423  } else {
424  snprintf(ret, sizeof(ret), "%s = %s - %s", r0, a0, a1);
425  }
426  break;
428  if (!a1 || !strcmp(a0, a1)) {
429  snprintf(ret, sizeof(ret), "%s *= %s", r0, a0);
430  } else {
431  snprintf(ret, sizeof(ret), "%s = %s * %s", r0, a0, a1);
432  }
433  break;
435  if (!a1 || !strcmp(a0, a1)) {
436  snprintf(ret, sizeof(ret), "%s /= %s", r0, a0);
437  } else {
438  snprintf(ret, sizeof(ret), "%s = %s / %s", r0, a0, a1);
439  }
440  break;
442  if (!a1 || !strcmp(a0, a1)) {
443  snprintf(ret, sizeof(ret), "%s &= %s", r0, a0);
444  } else {
445  snprintf(ret, sizeof(ret), "%s = %s & %s", r0, a0, a1);
446  }
447  break;
449  if (!a1 || !strcmp(a0, a1)) {
450  snprintf(ret, sizeof(ret), "%s |= %s", r0, a0);
451  } else {
452  snprintf(ret, sizeof(ret), "%s = %s | %s", r0, a0, a1);
453  }
454  break;
456  if (!a1 || !strcmp(a0, a1)) {
457  snprintf(ret, sizeof(ret), "%s ^= %s", r0, a0);
458  } else {
459  snprintf(ret, sizeof(ret), "%s = %s ^ %s", r0, a0, a1);
460  }
461  break;
463  snprintf(ret, sizeof(ret), "%s -> %s", r0, a0);
464  break;
466  memcpy(ret, ";", 2);
467  break;
469  memcpy(ret, "nop", 4);
470  break;
472  memcpy(ret, "ret", 4);
473  break;
475  if ((bb = rz_analysis_find_most_relevant_block_in(analysis, op->addr))) {
476  cstr = rz_analysis_cond_to_string(bb->cond);
477  snprintf(ret, sizeof(ret), "if (%s) ret", cstr);
478  free(cstr);
479  } else {
480  strcpy(ret, "if (unk) ret");
481  }
482  break;
484  memcpy(ret, "leave", 6);
485  break;
487  if (!a1 || !strcmp(a0, a1)) {
488  snprintf(ret, sizeof(ret), "%s %%= %s", r0, a0);
489  } else {
490  snprintf(ret, sizeof(ret), "%s = %s %% %s", r0, a0, a1);
491  }
492  break;
494  if (!a1 || !strcmp(a0, a1)) {
495  snprintf(ret, sizeof(ret), "tmp = %s; %s = %s; %s = tmp", r0, r0, a0, a0);
496  } else {
497  snprintf(ret, sizeof(ret), "%s = %s ^ %s", r0, a0, a1);
498  }
499  break;
504  RZ_LOG_DEBUG("Command not implemented.\n");
505  free(r0);
506  free(a0);
507  free(a1);
508  return NULL;
509  default:
510  free(r0);
511  free(a0);
512  free(a1);
513  return NULL;
514  }
515  free(r0);
516  free(a0);
517  free(a1);
518  return strdup(ret);
519 }
RZ_API char * rz_analysis_value_to_string(RzAnalysisValue *value)
Definition: value.c:83
RZ_API RzAnalysisBlock * rz_analysis_find_most_relevant_block_in(RzAnalysis *analysis, ut64 off)
Definition: block.c:997
RZ_API char * rz_analysis_cond_to_string(RzAnalysisCond *cond)
Definition: cond.c:63
RZ_DEPRECATE RZ_API RzAnalysisFunction * rz_analysis_get_fcn_in(RzAnalysis *analysis, ut64 addr, int type)
Definition: fcn.c:1687
a0
Definition: insn-good.s.cs:704
snprintf
Definition: kernel.h:364
memcpy(mem, inblock.get(), min(CONTAINING_RECORD(inblock.get(), MEMBLOCK, data) ->size, size))
@ RZ_ANALYSIS_FCN_TYPE_NULL
Definition: rz_analysis.h:192
@ RZ_ANALYSIS_OP_TYPE_SUB
Definition: rz_analysis.h:402
@ RZ_ANALYSIS_OP_TYPE_MUL
Definition: rz_analysis.h:404
@ RZ_ANALYSIS_OP_TYPE_ROL
Definition: rz_analysis.h:420
@ RZ_ANALYSIS_OP_TYPE_CASE
Definition: rz_analysis.h:424
@ RZ_ANALYSIS_OP_TYPE_AND
Definition: rz_analysis.h:411
@ RZ_ANALYSIS_OP_TYPE_MOD
Definition: rz_analysis.h:422
@ RZ_ANALYSIS_OP_TYPE_UPUSH
Definition: rz_analysis.h:395
@ RZ_ANALYSIS_OP_TYPE_RPUSH
Definition: rz_analysis.h:396
@ RZ_ANALYSIS_OP_TYPE_ROR
Definition: rz_analysis.h:419
@ RZ_ANALYSIS_OP_TYPE_LEAVE
Definition: rz_analysis.h:418
@ RZ_ANALYSIS_OP_TYPE_XCHG
Definition: rz_analysis.h:421
@ RZ_ANALYSIS_OP_TYPE_CCALL
Definition: rz_analysis.h:383
@ RZ_ANALYSIS_OP_TYPE_ADD
Definition: rz_analysis.h:401
@ RZ_ANALYSIS_OP_TYPE_SWITCH
Definition: rz_analysis.h:423
@ RZ_ANALYSIS_OP_TYPE_OR
Definition: rz_analysis.h:410
@ RZ_ANALYSIS_OP_TYPE_CRET
Definition: rz_analysis.h:386
@ RZ_ANALYSIS_OP_TYPE_DIV
Definition: rz_analysis.h:405
@ RZ_ANALYSIS_OP_TYPE_XOR
Definition: rz_analysis.h:412
#define PFMT64x
Definition: rz_types.h:393
#define f(i)
Definition: sha256.c:46
RzAnalysisCond * cond
Definition: rz_analysis.h:873

References a0, rz_analysis_bb_t::cond, f, free(), memcpy(), NULL, PFMT64x, r0, rz_analysis_cond_to_string(), RZ_ANALYSIS_FCN_TYPE_NULL, rz_analysis_find_most_relevant_block_in(), rz_analysis_get_fcn_in(), RZ_ANALYSIS_OP_TYPE_ADD, RZ_ANALYSIS_OP_TYPE_AND, RZ_ANALYSIS_OP_TYPE_CALL, RZ_ANALYSIS_OP_TYPE_CASE, RZ_ANALYSIS_OP_TYPE_CCALL, RZ_ANALYSIS_OP_TYPE_CJMP, RZ_ANALYSIS_OP_TYPE_CMP, RZ_ANALYSIS_OP_TYPE_CRET, RZ_ANALYSIS_OP_TYPE_DIV, RZ_ANALYSIS_OP_TYPE_ICALL, RZ_ANALYSIS_OP_TYPE_IJMP, RZ_ANALYSIS_OP_TYPE_IRCALL, RZ_ANALYSIS_OP_TYPE_IRJMP, RZ_ANALYSIS_OP_TYPE_JMP, RZ_ANALYSIS_OP_TYPE_LEA, RZ_ANALYSIS_OP_TYPE_LEAVE, RZ_ANALYSIS_OP_TYPE_MOD, RZ_ANALYSIS_OP_TYPE_MOV, RZ_ANALYSIS_OP_TYPE_MUL, RZ_ANALYSIS_OP_TYPE_NOP, RZ_ANALYSIS_OP_TYPE_OR, RZ_ANALYSIS_OP_TYPE_POP, RZ_ANALYSIS_OP_TYPE_PUSH, RZ_ANALYSIS_OP_TYPE_RCALL, RZ_ANALYSIS_OP_TYPE_RET, RZ_ANALYSIS_OP_TYPE_RJMP, RZ_ANALYSIS_OP_TYPE_ROL, RZ_ANALYSIS_OP_TYPE_ROR, RZ_ANALYSIS_OP_TYPE_RPUSH, RZ_ANALYSIS_OP_TYPE_SUB, RZ_ANALYSIS_OP_TYPE_SWITCH, RZ_ANALYSIS_OP_TYPE_UCALL, RZ_ANALYSIS_OP_TYPE_UJMP, RZ_ANALYSIS_OP_TYPE_UPUSH, RZ_ANALYSIS_OP_TYPE_XCHG, RZ_ANALYSIS_OP_TYPE_XOR, rz_analysis_value_to_string(), RZ_LOG_DEBUG, snprintf, and strdup().

Referenced by ds_build_op_str(), rz_core_disasm_pdi_with_buf(), and rz_core_print_disasm_instructions_with_buf().

◆ rz_analysis_optype_from_string()

RZ_API int rz_analysis_optype_from_string ( RZ_NONNULL const char *  name)

Return the op type corresponding the given name

Parameters
namestring, name of the optype
Returns
type int, id of the op type (one of _RzAnalysisOpType)

Definition at line 294 of file op.c.

294  {
296  int i;
297  for (i = 0; RZ_ARRAY_SIZE(optypes); i++) {
298  if (!strcmp(optypes[i].name, name)) {
299  return optypes[i].type;
300  }
301  }
302  return -1;
303 }
static struct optype optypes[]
int type
Definition: op.c:223

References i, optypes, RZ_ARRAY_SIZE, rz_return_val_if_fail, and optype::type.

Referenced by rz_analysis_hint_set_optype_handler().

◆ rz_analysis_optype_to_string()

RZ_API const char* rz_analysis_optype_to_string ( int  type)

Return the name of the given op type

Parameters
typeint, id of the op type (one of _RzAnalysisOpType)
Returns
name string, string, name of the optype

Definition at line 310 of file op.c.

310  {
311  int i;
312 
313  for (i = 0; i < RZ_ARRAY_SIZE(optypes); i++) {
314  if (optypes[i].type == type) {
315  return optypes[i].name;
316  }
317  }
318 
320 
321  for (i = 0; i < RZ_ARRAY_SIZE(optypes); i++) {
322  if (optypes[i].type == type) {
323  return optypes[i].name;
324  }
325  }
326  return "undefined";
327 }
int type
Definition: mipsasm.c:17
const char * name
Definition: op.c:224

References i, optype::name, optypes, RZ_ANALYSIS_OP_TYPE_MASK, RZ_ARRAY_SIZE, and type.

Referenced by anop32(), core_analysis_bytes_json(), core_analysis_bytes_standard(), do_analysis_search(), ds_must_strip(), ds_print_optype(), hint_node_print(), print_hint_h_format(), print_rop(), rz_core_disasm_pde(), rz_core_print_disasm_json(), showanalysis(), step_until_optype(), and update_stat_for_op().

◆ rz_analysis_stackop_tostring()

RZ_API const char* rz_analysis_stackop_tostring ( int  s)

Definition at line 521 of file op.c.

521  {
522  switch (s) {
524  return "null";
526  return "nop";
528  return "inc";
530  return "get";
532  return "set";
534  return "reset";
535  }
536  return "unk";
537 }
static RzSocket * s
Definition: rtr.c:28
@ RZ_ANALYSIS_STACK_RESET
Definition: rz_analysis.h:460
@ RZ_ANALYSIS_STACK_SET
Definition: rz_analysis.h:459
@ RZ_ANALYSIS_STACK_GET
Definition: rz_analysis.h:458
@ RZ_ANALYSIS_STACK_NULL
Definition: rz_analysis.h:455
@ RZ_ANALYSIS_STACK_INC
Definition: rz_analysis.h:457
@ RZ_ANALYSIS_STACK_NOP
Definition: rz_analysis.h:456

References RZ_ANALYSIS_STACK_GET, RZ_ANALYSIS_STACK_INC, RZ_ANALYSIS_STACK_NOP, RZ_ANALYSIS_STACK_NULL, RZ_ANALYSIS_STACK_RESET, RZ_ANALYSIS_STACK_SET, and s.

Referenced by core_analysis_bytes_json(), and core_analysis_bytes_standard().

Variable Documentation

◆ id

int id

Definition at line 540 of file op.c.

Referenced by _zip_ef_delete_by_id(), _zip_ef_new(), avr_AAAAAbbb(), avr_AAdddddAAAA(), avr_AArrrrrAAAA(), avr_dddcrrr(), avr_ddddcccc(), avr_dddddcbbb(), avr_dddddcccc(), avr_dddddcccc_load32(), avr_dddddcccc_store32(), avr_dddddcccc_x(), avr_dddddcccc_xm(), avr_dddddcccc_xp(), avr_dddddcccc_y(), avr_dddddcccc_ym(), avr_dddddcccc_yp(), avr_dddddcccc_z(), avr_dddddcccc_zm(), avr_dddddcccc_zp(), avr_ddddrrrr(), avr_ddddrrrr_2x(), avr_KKddKKKK(), avr_kkkddddkkkk_load16(), avr_kkkddddkkkk_store16(), avr_KKKKcccc(), avr_KKKKddddKKKK(), avr_kkkkkccck(), avr_kkkkkkkccc(), avr_kkkkkkkkkkkk(), avr_qcqqcdddddcqqq_y(), avr_qcqqcdddddcqqq_z(), avr_qcqqcrrrrrcqqq_y(), avr_qcqqcrrrrrcqqq_z(), avr_rdddddrrrr(), avr_rrrrrcbbb(), avr_rrrrrcccc_x(), avr_rrrrrcccc_xm(), avr_rrrrrcccc_xp(), avr_rrrrrcccc_y(), avr_rrrrrcccc_ym(), avr_rrrrrcccc_yp(), avr_rrrrrcccc_z(), avr_rrrrrcccc_zm(), avr_rrrrrcccc_zp(), avr_spmz(), avr_unique(), capture_list_pool_get(), capture_list_pool_get_mut(), capture_list_pool_release(), coder_add_filter(), d_substitution(), get_extra(), insn_find(), kd_send_ctrl_packet(), kd_send_data_packet(), M68K_get_insn_id(), M68K_insn_name(), oids_od_binsert(), rz_convert_mne_handler(), rz_id_storage_delete(), rz_id_storage_get(), rz_id_storage_get_next(), rz_id_storage_get_prev(), rz_id_storage_set(), rz_oids_add(), rz_oids_foreach(), rz_oids_foreach_prev(), rz_oids_oget(), rz_oids_sort(), rz_oids_to_front(), rz_oids_to_rear(), RZ_PACKED(), rz_x509_crlentry_dump(), symbol_table_insert_name(), symbol_table_name_for_id(), ts_language_field_name_for_id(), ts_tree_cursor_current_field_name(), and wasm_dis().

◆ name

static void struct sockaddr socklen_t static fromlen static backlog static fork char char char static envp int struct rusage static rusage struct utsname static buf struct sembuf static nsops static fd const char static length unsigned struct dirent unsigned static count const char const char static newpath const char static pathname const char const char static newpath const char const char static newpath const char static mode const char static group const char static group struct timeval struct timezone static tz struct tms static buf static getuid static getgid static getegid static getppid static setsid static egid static suid static pid static fsgid static data const char static dev unsigned static persona const char struct statfs static buf unsigned char static buf static prio struct sched_param static p static policy struct timespec static tp const void static len static munlockall const char static path const char static filename const char static path const char static len unsigned unsigned static turn_on const char name

Definition at line 541 of file op.c.

Referenced by __func_name_from_ord(), _zip_guess_encoding(), _zip_hash_add(), aarch64_symbol_is_valid(), args_parse(), bin_pe_init_sections(), bin_pe_parse_imports(), bopen(), c_parser_new_anonymous_callable_name(), c_parser_new_anonymous_enum_name(), c_parser_new_anonymous_structure_name(), c_parser_new_anonymous_union_name(), check_features(), chmd_read_headers(), cmd_foreach_cmdname_modes(), cmd_print_format(), core_recover_golang_functions_go_1_16(), core_recover_golang_functions_go_1_18(), core_recover_golang_functions_go_1_2(), cplus_demangle_fill_ctor(), cplus_demangle_fill_dtor(), cplus_demangle_fill_extended_operator(), create_class_type(), create_output_name(), create_si_class_type(), create_vmi_class_type(), d_expression_1(), d_identifier(), d_local_name(), d_make_sub(), diff_output_start_file(), ds_print_calls_hints(), ds_show_xrefs(), find_ipa_binary(), get_die_name(), get_ivar_list_t(), get_method_list_t(), get_operator_code(), get_regname(), get_sym_code_type(), gzscan(), imports(), insn_to_str(), is_cab_using_unix_paths(), is_special_char(), key_class(), lastNameFromPath(), le_get_symbol(), linux_handle_signals(), load_spanning_cabinets(), main(), main_print_var(), meta_string_guess_add(), parse_atomic_type(), parse_enumerator(), parse_options(), parse_struct_member(), parse_symbol_table(), parse_typedef(), pdb_set_symbols(), print_comment(), print_insn_sparc(), print_stats(), process_cabinet(), read_name(), read_str(), recovery_apply_complete_object_locator(), recovery_apply_type_descriptor(), resolve_path(), rtti_itanium_read_type_name_custom(), rz_analysis_extract_rarg(), rz_analysis_function_name_guess(), rz_analysis_il_init_state_set_var(), rz_analysis_noreturn_add(), rz_bin_elf_get_osabi_name(), rz_bin_filter_name(), rz_bin_force_plugin(), rz_bin_java_class_fields_as_text(), rz_bin_java_class_methods_as_text(), rz_bin_ne_get_imports(), rz_bin_ne_get_symbols(), rz_bin_select(), rz_cmd_macro_add(), rz_core_analysis_autoname_all_fcns(), rz_core_analysis_fcn_name(), rz_core_bin_pdb_gvars_as_string(), rz_core_rtr_add(), rz_core_rtr_gdb_cb(), rz_core_run_script(), rz_core_types_function_print_all(), rz_core_visual_cmd(), rz_core_visual_define(), rz_core_visual_xrefs(), rz_eval_spaces_handler(), rz_file_mkstemp(), rz_il_reg_binding_derive(), rz_io_zip_open(), rz_main_rz_bin(), rz_main_version_verify(), rz_name_filter(), RZ_PACKED(), rz_reg_is_readonly(), rz_syscmd_ls(), rz_table_set_vcolumnsf(), rz_type_noreturn_del_all_handler(), sdb_load_platform_profile(), sdb_load_sysregs(), sep64_xtr_ctx_get_slice(), set_filename_printable_name(), set_name(), set_note_file(), unique_class_name(), unix_path_seperators(), uv__random_sysctl(), walkSymbols(), xtensa_state_lookup(), xtensa_sysreg_lookup_name(), zip_delete(), and zip_stat_index().

◆ 

const { ... } op_families[]
Initial value:
= {
}
@ RZ_ANALYSIS_OP_FAMILY_FPU
Definition: rz_analysis.h:313
@ RZ_ANALYSIS_OP_FAMILY_THREAD
Definition: rz_analysis.h:318
@ RZ_ANALYSIS_OP_FAMILY_CRYPTO
Definition: rz_analysis.h:317
@ RZ_ANALYSIS_OP_FAMILY_SSE
Definition: rz_analysis.h:315
@ RZ_ANALYSIS_OP_FAMILY_PRIV
Definition: rz_analysis.h:316
@ RZ_ANALYSIS_OP_FAMILY_CPU
Definition: rz_analysis.h:312
@ RZ_ANALYSIS_OP_FAMILY_MMX
Definition: rz_analysis.h:314
@ RZ_ANALYSIS_OP_FAMILY_VIRT
Definition: rz_analysis.h:319
@ RZ_ANALYSIS_OP_FAMILY_IO
Definition: rz_analysis.h:321
@ RZ_ANALYSIS_OP_FAMILY_SECURITY
Definition: rz_analysis.h:320

Referenced by rz_analysis_op_family_from_string(), and rz_analysis_op_family_to_string().

◆ optypes

struct optype optypes[]
static