MCPcopy Create free account
hub / github.com/Vector35/binaryninja-api / LDR_lit_gen

Function LDR_lit_gen

arch/arm64/disassembler/decode2.c:15286–15315  ·  view source on GitHub ↗

ldr_lit_gen.xml */

Source from the content-addressed store, hash-verified

15284
15285/* ldr_lit_gen.xml */
15286int LDR_lit_gen(context *ctx, Instruction *instr)
15287{
15288 int rc = DECODE_STATUS_UNMATCHED;
15289 /* class iclass_literal */
15290 /* opc=0x|011|V=0|00|imm19=xxxxxxxxxxxxxxxxxxx|Rt=xxxxx */
15291 if((INSWORD & 0xBF000000)==0x18000000) {
15292 decode_fields32(ENC_LDR_32_LOADLIT, ctx, instr);
15293 ctx->t = UINT(ctx->Rt);
15294 ctx->memop = MemOp_LOAD;
15295 ctx->signed_ = FALSE;
15296 if(!ctx->opc) {
15297 ctx->size = 4;
15298 }
15299 else if(ctx->opc==1) {
15300 ctx->size = 8;
15301 }
15302 else if(ctx->opc==2) {
15303 ctx->size = 4;
15304 ctx->signed_ = TRUE;
15305 }
15306 else if(ctx->opc==3) {
15307 ctx->memop = MemOp_PREFETCH;
15308 }
15309 ctx->offset = SignExtend((ctx->imm19<<2),21);
15310 ctx->tag_checked = FALSE;
15311 if(ctx->opc==0) OK(ENC_LDR_32_LOADLIT);
15312 if(ctx->opc==1) OK(ENC_LDR_64_LOADLIT);
15313 }
15314 return rc;
15315}
15316
15317/* ldr_reg_fpsimd.xml */
15318int LDR_reg_fpsimd(context *ctx, Instruction *instr)

Callers 1

decode_iclass_loadlitFunction · 0.85

Calls 2

decode_fields32Function · 0.85
SignExtendFunction · 0.85

Tested by

no test coverage detected