qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Hajnoczi <stefanha@gmail.com>
To: Thomas Knauth <thomas.knauth@gmx.de>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] Capture SIGSEGV to track pc.ram page access
Date: Fri, 27 Sep 2013 12:50:32 +0200	[thread overview]
Message-ID: <20130927105032.GF9972@stefanha-thinkpad.redhat.com> (raw)
In-Reply-To: <CABhLV02mAUbZS0nFE9KauSPgr36SZT0mF=EsGHfbKT=0SA7XYQ@mail.gmail.com>

On Thu, Sep 26, 2013 at 02:53:54PM +0200, Thomas Knauth wrote:
> As far as I understand the dirty logging infrastructure will only
> record writes. I want to track reads as well.
> 
> A better way to express what I would like to do is trace all guest
> physical addresses that are accessed. Again, I am unsure whether qemu
> supports this out-of-the box and where I would have to add/modify the
> source to do so.

If you want to continue with the original SIGSEGV handler approach,
check signals masks for the vcpu threads.  Make sure the signal actually
gets delivered to a thread that has the signal unblocked and a signal
handler installed.

Regarding dirty logging, you could try modifying the KVM dirty logging
code to also trap reads.

Also take a look at /proc/PID/pagemap and documentation on accessing
this page table info.  It can be used for tracking dirty pages
("soft-dirty") but I'm not sure if it reports accessed pages.

Stefan

  reply	other threads:[~2013-09-27 10:50 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-01  9:38 [Qemu-devel] Capture SIGSEGV to track pc.ram page access Thomas Knauth
2013-09-02  9:16 ` Stefan Hajnoczi
2013-09-26 12:53   ` Thomas Knauth
2013-09-27 10:50     ` Stefan Hajnoczi [this message]
2013-10-08 16:22       ` Thomas Knauth

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=20130927105032.GF9972@stefanha-thinkpad.redhat.com \
    --to=stefanha@gmail.com \
    --cc=qemu-devel@nongnu.org \
    --cc=thomas.knauth@gmx.de \
    /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 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).