Type Alias simics_api_sys::cpu_address_cb_t

source ·
pub type cpu_address_cb_t = Option<unsafe extern "C" fn(obj: *mut conf_object_t, cpu: *mut conf_object_t, address: logical_address_t, handle: *mut address_handle_t, user_data: *mut lang_void) -> logical_address_t>;
Expand description
cpu_address_cb_t cpu_address_cb_t cpu_address_cb_t

Instrumentation callback function registered through the cpu_instrumentation_subscribe interface’s register_address_before() member function.

The callback will be called prior to a processor memory access, allowing the callback to change the logical address for an access.

The argument obj is the object installing the callback and the cpu is the processor generating the logical address. If the access crosses a page boundary the access will be split into two calls. The part argument tells if the address belongs to the first or the second part. The cpu_address_part_t type has two values: CPU_Address_Part_First and CPU_Address_Part_Second. The handle can be used to extract more information about he address by using a architecture specific interface. See the x86_address_query for example.

Aliased Type§

enum cpu_address_cb_t {
    None,
    Some(unsafe extern "C" fn(_: *mut conf_object, _: *mut conf_object, _: u64, _: *mut cpu_address_info, _: *mut c_void) -> u64),
}

Variants§

§1.0.0

None

No value.

§1.0.0

Some(unsafe extern "C" fn(_: *mut conf_object, _: *mut conf_object, _: u64, _: *mut cpu_address_info, _: *mut c_void) -> u64)

Some value of type T.