qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Memory callback


From: Super Man
Subject: Memory callback
Date: Wed, 8 Jul 2020 21:53:59 +0800

Sorry to bother you, I would like to ask a question.I want to use qemu to monitor the information of the target thread reading and writing memory. I see that qemu supports the tcg plugin, but I just find the following code in plugin-gen.c .Do I just need to add a record function in it? How do I read the current register values such as rip, rsp, how do I know the current target address and data that the CPU read or written?Is there any reference example?

/*
* These helpers are stubs that get dynamically switched out for calls
* direct to the plugin if they are subscribed to.
*/
void HELPER(plugin_vcpu_udata_cb)(uint32_t cpu_index, void *udata)
{ }
void HELPER(plugin_vcpu_mem_cb)(unsigned int vcpu_index,
qemu_plugin_meminfo_t info, uint64_t vaddr,
void *userdata)
{ }

reply via email to

[Prev in Thread] Current Thread [Next in Thread]