From: "Lluís Vilanova" <vilanova@ac.upc.edu>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: Paolo Bonzini <pbonzini@redhat.com>,
Richard Henderson <rth@twiddle.net>,
QEMU Developers <qemu-devel@nongnu.org>,
Stefan Hajnoczi <stefanha@redhat.com>,
Peter Crosthwaite <crosthwaite.peter@gmail.com>
Subject: Re: [Qemu-devel] [PATCH 2/5] trace: [all] Add "guest_vmem" event
Date: Thu, 17 Mar 2016 20:22:52 +0100 [thread overview]
Message-ID: <8737rorjsj.fsf@fimbulvetr.bsc.es> (raw)
In-Reply-To: <CAFEAcA-yoUGYjOu9_1jtQmGv50p1gWCiYb3Hq+UQsVAw=JS1UA@mail.gmail.com> (Peter Maydell's message of "Wed, 16 Mar 2016 15:01:09 +0000")
Peter Maydell writes:
> On 23 February 2016 at 18:22, Lluís Vilanova <vilanova@ac.upc.edu> wrote:
>> Signed-off-by: Lluís Vilanova <vilanova@ac.upc.edu>
>> +### Guest events, keep at bottom
>> +
>> +# @vaddr: Access' virtual address.
>> +# @size : Access' size (bytes).
>> +# @store: Whether the access is a store.
>> +#
>> +# Start virtual memory access (before any potential access violation).
>> +#
>> +# Does not include memory accesses performed by devices.
>> +#
>> +# Targets: TCG(all)
>> +disable vcpu tcg guest_vmem(TCGv vaddr, uint8_t size, uint8_t store) "size=%d store=%d", "vaddr=0x%016"PRIx64" size=%d store=%d"
> Shouldn't we also be tracing some of the other information in the memop?
> In particular, endianness of the access seems useful. You could also
> say whether we're zero- or sign-extending the access, though I guess
> you could defend not printing that since we don't print anything about
> what the target- code does with the loaded data.
> Otherwise I think this looks OK (though the various paths memory accesses
> take are a bit opaque since I've forgotten how this bit of QEMU works).
Mmmmm, the endianness seems more of a vCPU property than one of the memory
access. A separate event could be added for that (e.g., at vCPU
initalization/hot-plug and whenever it is dynamically changed like in ARM).
For the sign extension and memory value, what about adding multiple events?
What I did for instructions is have a simple event and one with extended
information, so that we can tweak performance of a tracing QEMU by choosing one
or the other. We could do the same for memory accesses (e.g., also show the
memory value, sign extension and physical address).
next prev parent reply other threads:[~2016-03-17 19:23 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-23 18:22 [Qemu-devel] [PATCH 0/5] trace: Add events for vCPU memory accesses Lluís Vilanova
2016-02-23 18:22 ` [Qemu-arm] [PATCH 1/5] exec: [tcg] Track which vCPU is performing translation and execution Lluís Vilanova
2016-02-23 18:22 ` [Qemu-devel] " Lluís Vilanova
2016-03-16 15:01 ` [Qemu-arm] " Peter Maydell
2016-03-16 15:01 ` [Qemu-devel] " Peter Maydell
2016-02-23 18:22 ` [Qemu-devel] [PATCH 2/5] trace: [all] Add "guest_vmem" event Lluís Vilanova
2016-03-16 15:01 ` Peter Maydell
2016-03-17 19:22 ` Lluís Vilanova [this message]
2016-03-17 20:18 ` Richard Henderson
2016-03-17 20:25 ` Peter Maydell
2016-03-18 18:50 ` Lluís Vilanova
2016-03-19 13:59 ` Peter Maydell
2016-03-20 18:09 ` Lluís Vilanova
2016-03-20 19:59 ` Peter Maydell
2016-03-21 16:51 ` Lluís Vilanova
2016-02-23 18:22 ` [Qemu-devel] [PATCH 3/5] user: Refactor lock_user body into do_lock_user Lluís Vilanova
2016-02-23 18:22 ` [Qemu-devel] [PATCH 4/5] user: Set current vCPU during syscall execution Lluís Vilanova
2016-02-23 18:22 ` [Qemu-devel] [PATCH 5/5] trace: [all] Add "guest_vmem_user_syscall" event Lluís Vilanova
2016-03-02 10:55 ` [Qemu-devel] [PATCH 0/5] trace: Add events for vCPU memory accesses Stefan Hajnoczi
2016-03-16 15:10 ` Peter Maydell
2016-03-22 12:55 ` Stefan Hajnoczi
2016-03-22 14:02 ` Lluís Vilanova
2016-03-22 14:47 ` Peter Maydell
2016-03-22 19:23 ` Lluís Vilanova
2016-03-22 20:23 ` Peter Maydell
2016-03-23 14:08 ` Lluís Vilanova
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8737rorjsj.fsf@fimbulvetr.bsc.es \
--to=vilanova@ac.upc.edu \
--cc=crosthwaite.peter@gmail.com \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=rth@twiddle.net \
--cc=stefanha@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.