Lines Matching refs:addr_expr
314 static Bool is_stack_access(IRSB* const bb, IRExpr* const addr_expr) in is_stack_access() argument
318 if (addr_expr->tag == Iex_RdTmp) in is_stack_access()
325 && bb->stmts[i]->Ist.WrTmp.tmp == addr_expr->Iex.RdTmp.tmp) in is_stack_access()
352 static IRExpr* instr_trace_mem_load(IRSB* const bb, IRExpr* addr_expr, in instr_trace_mem_load() argument
358 tmp = newIRTemp(bb->tyenv, typeOfIRExpr(bb->tyenv, addr_expr)); in instr_trace_mem_load()
359 addStmtToIRSB(bb, IRStmt_WrTmp(tmp, addr_expr)); in instr_trace_mem_load()
360 addr_expr = IRExpr_RdTmp(tmp); in instr_trace_mem_load()
366 mkIRExprVec_2(addr_expr, mkIRExpr_HWord(size))); in instr_trace_mem_load()
370 return addr_expr; in instr_trace_mem_load()
376 static void instr_trace_mem_store(IRSB* const bb, IRExpr* const addr_expr, in instr_trace_mem_store() argument
468 mkIRExprVec_4(addr_expr, mkIRExpr_HWord(size), in instr_trace_mem_store()
475 static void instrument_load(IRSB* const bb, IRExpr* const addr_expr, in instrument_load() argument
483 if (!s_check_stack_accesses && is_stack_access(bb, addr_expr)) in instrument_load()
489 argv = mkIRExprVec_1(addr_expr); in instrument_load()
496 argv = mkIRExprVec_1(addr_expr); in instrument_load()
503 argv = mkIRExprVec_1(addr_expr); in instrument_load()
510 argv = mkIRExprVec_1(addr_expr); in instrument_load()
518 argv = mkIRExprVec_2(addr_expr, size_expr); in instrument_load()
529 static void instrument_store(IRSB* const bb, IRExpr* addr_expr, in instrument_store() argument
541 IRTemp tmp = newIRTemp(bb->tyenv, typeOfIRExpr(bb->tyenv, addr_expr)); in instrument_store()
542 addStmtToIRSB(bb, IRStmt_WrTmp(tmp, addr_expr)); in instrument_store()
543 addr_expr = IRExpr_RdTmp(tmp); in instrument_store()
544 instr_trace_mem_store(bb, addr_expr, NULL, data_expr, guard_expr); in instrument_store()
547 if (!s_check_stack_accesses && is_stack_access(bb, addr_expr)) in instrument_store()
553 argv = mkIRExprVec_1(addr_expr); in instrument_store()
560 argv = mkIRExprVec_1(addr_expr); in instrument_store()
567 argv = mkIRExprVec_1(addr_expr); in instrument_store()
574 argv = mkIRExprVec_1(addr_expr); in instrument_store()
582 argv = mkIRExprVec_2(addr_expr, size_expr); in instrument_store()
668 IRExpr* addr_expr = lg->addr; in DRD_() local
672 addr_expr = instr_trace_mem_load(bb, addr_expr, in DRD_()
684 IRExpr* addr_expr = data->Iex.Load.addr; in DRD_() local
687 addr_expr = instr_trace_mem_load(bb, addr_expr, in DRD_()
691 instrument_load(bb, addr_expr, sizeofIRType(data->Iex.Load.ty), in DRD_()
775 IRExpr* addr_expr = st->Ist.LLSC.addr; in DRD_() local
777 addr_expr = instr_trace_mem_load(bb, addr_expr, in DRD_()
781 instrument_load(bb, addr_expr, sizeofIRType(dataTy), in DRD_()