qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] memory trace with qemu


From: Stefan Hajnoczi
Subject: Re: [Qemu-devel] memory trace with qemu
Date: Sat, 24 Jul 2010 10:05:31 +0100

On Sat, Jul 24, 2010 at 3:17 AM, Yufei Chen <address@hidden> wrote:
> On Fri, Jul 23, 2010 at 2:15 PM, Stefan Hajnoczi <address@hidden> wrote:
>> On Fri, Jul 23, 2010 at 4:12 AM, Mulyadi Santosa
>> <address@hidden> wrote:
>>> Hi...
>>>
>>> On Fri, Jul 23, 2010 at 05:30, Eduardo Cruz <address@hidden> wrote:
>>>> Hello, I need qemu to keep track of all the memory access made by the 
>>>> guest,
>>>> including read, write and the instruction fetches.
>
> I don't think Qemu can provide cycle number information. But other
> information are all available.
>
>>>
>>> AFAIK there are lots of experiments on this and has produces working
>>> patches...at least from the posting of the creator. There is even a
>>> patch floating to start creating trace framework a while ago.
>>
>> Thanks Mulyadi, I think you are referring to the tracing work that
>> Prerna Saxena and I are doing.  Here is the documentation:
>>
>> http://repo.or.cz/w/qemu/stefanha.git/blob/tracing:/docs/tracing.txt
>>
>> The patches apply to qemu.git.  You can define trace events in the
>> trace-events file and then call them from places in the code.  There
>> is a script to pretty-print the binary trace file that QEMU produces.
>>
>> Eduardo, if you think this might be what you're looking for, please
>> give it a try.  I am on #qemu and #kvm IRC if you need any help.  Any
>> feedback will be valuable to us as we prepare these patches for
>> submission to qemu.git.
>>
>> I believe the tracing framework answers the "Any ideas of how I can
>> record these information with qemu?" part of your question :).  I
>> don't have experience in the TCG, so I can't give advice on how to
>> best get at the memory accesses, but I hope this helps you one step
>> further.
>>
>
> Can this framework trace memory access event? I guess this would be
> more difficult to do in KVM than in TCG.

No, it can't trace memory accesses.  It provides you with the ability
to put trace events into QEMU, but there is current no pre-defined
trace event for memory access.

If you find the right spot to in TCG it should be easy to add a trace
event there.  I agree, with KVM is would be more difficult and perhaps
defeat the point of KVM :).

Stefan

>> Stefan
>>
>>> perhaps you could dig a little deeper in qemu archieve....?
>>>
>>> --
>>> regards,
>>>
>>> Mulyadi Santosa
>>> Freelance Linux trainer and consultant
>>>
>>> blog: the-hydra.blogspot.com
>>> training: mulyaditraining.blogspot.com
>>>
>>>
>>
>>
>
>
>
> --
> Best regards,
> Chen Yufei
>



reply via email to

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