Rizin
unix-like reverse engineering framework and cli tools
avr_il.h File Reference

Go to the source code of this file.

Functions

RZ_IPI bool rz_avr_il_opcode (RzAnalysis *analysis, RzAnalysisOp *op, ut64 pc, AVROp *aop, AVROp *next_op)
 
RZ_IPI RzAnalysisILConfigrz_avr_il_config (RZ_NONNULL RzAnalysis *analysis)
 

Function Documentation

◆ rz_avr_il_config()

RZ_IPI RzAnalysisILConfig* rz_avr_il_config ( RZ_NONNULL RzAnalysis analysis)

Definition at line 3156 of file avr_il.c.

3156  {
3157  rz_return_val_if_fail(analysis, NULL);
3158 
3160  r->reg_bindings = avr_global_registers;
3161  return r;
3162 }
RZ_API RZ_OWN RzAnalysisILConfig * rz_analysis_il_config_new(ut32 pc_size, bool big_endian, ut32 mem_key_size)
Definition: analysis_il.c:53
#define AVR_ADDR_SIZE
Definition: avr_il.c:20
static const char * avr_global_registers[]
Definition: avr_il.c:105
#define NULL
Definition: cris-opc.c:27
#define r
Definition: crypto_rc6.c:12
#define rz_return_val_if_fail(expr, val)
Definition: rz_assert.h:108
Description of the global context of an RzAnalysisILVM.
Definition: rz_analysis.h:1134

References AVR_ADDR_SIZE, avr_global_registers, NULL, r, rz_analysis_il_config_new(), and rz_return_val_if_fail.

◆ rz_avr_il_opcode()

RZ_IPI bool rz_avr_il_opcode ( RzAnalysis analysis,
RzAnalysisOp op,
ut64  pc,
AVROp aop,
AVROp next_op 
)

Definition at line 3143 of file avr_il.c.

3143  {
3144  rz_return_val_if_fail(analysis && op && aop && next_op, false);
3145  if (aop->mnemonic >= AVR_OP_SIZE) {
3146  RZ_LOG_ERROR("RzIL: AVR: out of bounds op\n");
3147  return false;
3148  }
3149 
3150  avr_il_op create_op = avr_ops[aop->mnemonic];
3151  op->il_op = create_op(aop, next_op, pc, analysis);
3152 
3153  return true;
3154 }
@ AVR_OP_SIZE
Definition: disassembler.h:125
RzILOpEffect *(* avr_il_op)(AVROp *aop, AVROp *next_op, ut64 pc, RzAnalysis *analysis)
Definition: avr_il.c:3024
static avr_il_op avr_ops[AVR_OP_SIZE]
Definition: avr_il.c:3026
#define RZ_LOG_ERROR(fmtstr,...)
Definition: rz_log.h:58
AVROpMnem mnemonic
Definition: disassembler.h:129
Definition: dis.c:32

References AVR_OP_SIZE, avr_ops, avr_opcode_t::mnemonic, pc, RZ_LOG_ERROR, and rz_return_val_if_fail.

Referenced by avr_op().