[panda-users] Adding a callback for clflush/clflushopt/clwb

Vincent Lee vincent_lee at utexas.edu
Sun Mar 18 14:59:13 EDT 2018


Hi all,

I'd like to communicate to a plugin whenever a (x86_64) guest calls the
clflush, clflushopt, or clwb instructions.
Does anyone have any pointers or documentation where I should look to begin
implementing this?

>From what I can tell so far:
* TCG translation of clwb/clflush/clflushopt simply call "gen_nop_modrm",
which does nothing
* TCG->native codegen is where panda's memory hooks are inserted

Would this be a valid (if ad-hoc) plan?
* Modify QEMU TCG to have some concept of "clflush/clwb/clflushopt" and
emit this from code->TCG translation
* add a new panda callback type for "clflush/clwb/clflushopt"
* change TCG->native codegen to inject a call to panda callbacks

Thanks,
Vincent
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.mit.edu/pipermail/panda-users/attachments/20180318/b2304725/attachment.html


More information about the panda-users mailing list