pub unsafe extern "C" fn drreg_restore_app_values(
drcontext: *mut c_void,
ilist: *mut instrlist_t,
where_: *mut instr_t,
opnd: opnd_t,
swap: *mut reg_id_t,
) -> drreg_status_tExpand description
This is a convenience routine that calls drreg_get_app_value() for every register used by \p opnd, with that register passed as the application and destination registers. This routine will write to reserved as well as unreserved registers. This is intended as a convenience barrier for lazy restores performed by drreg.
If called during drmgr’s insertion phase, \p where must be the current application instruction.
On ARM, asking to place the application value of the register returned by dr_get_stolen_reg() into itself is not supported. If \p opnd uses the stolen register, this routine will swap it for a scratch register. This scratch register will be \p *swap if \p *swap is not #DR_REG_NULL; otherwise, drreg_reserve_register() with NULL for \p reg_allowed will be called, and the result returned in \p *swap. It is up to the caller to un-reserve the register in that case.
@return whether successful or an error code on failure. On failure, any values that were already restored are not undone.