qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [RFC] Tracing guest register usage
@ 2016-09-28 13:21 Lluís Vilanova
  2016-09-28 17:18 ` Richard Henderson
  0 siblings, 1 reply; 6+ messages in thread
From: Lluís Vilanova @ 2016-09-28 13:21 UTC (permalink / raw)
  To: qemu-devel; +Cc: Paolo Bonzini, Peter Crosthwaite, Richard Henderson

Hi! I've kept working on extending the guest instruction tracing features, and
added support to trace which registers are read/written by guest instructions
(when executing with TCG).

I've basically extended "tcg_global_mem_new_*" to associate global TCG registers
with a guest (vCPU) register number (*), and track all TCG opcodes that access
the values of these global TCG registers.

(*) This "mapping" is necessary because targets like i386 have multiple global
    TCG registers (cc_dst, cc_src, ...) that correspond to a single guest
    register (eflags).

While enough, I'm wondering if extending "tcg_global_mem_new_*" to set that
mapping is the proper way to go. For example, gdbstub also has some form of
guest (vCPU) register descriptors, but only for some of the targets.

So the question is wether it's worth generalizing this to some register
descriptors in CPUClass, that can be used by all QEMU's subsystems.


Cheers,
  Lluis

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2016-10-05 16:16 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-09-28 13:21 [Qemu-devel] [RFC] Tracing guest register usage Lluís Vilanova
2016-09-28 17:18 ` Richard Henderson
2016-09-30 15:13   ` Lluís Vilanova
2016-09-30 18:56     ` Richard Henderson
2016-10-05 10:06       ` Lluís Vilanova
2016-10-05 16:16         ` Richard Henderson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).