All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Dr. David Alan Gilbert (git)" <dgilbert@redhat.com>
To: qemu-devel@nongnu.org, borntraeger@de.ibm.com,
	quintela@redhat.com, lvivier@redhat.com, peterx@redhat.com
Subject: [Qemu-devel] [PATCH 2/2] migration: Extra tracing
Date: Wed, 26 Apr 2017 19:37:21 +0100	[thread overview]
Message-ID: <20170426183721.7482-3-dgilbert@redhat.com> (raw)
In-Reply-To: <20170426183721.7482-1-dgilbert@redhat.com>

From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>

A couple more traces that would have made fixing that postcopy
bug a bit easier.

Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
---
 migration/ram.c        | 2 ++
 migration/trace-events | 2 ++
 2 files changed, 4 insertions(+)

diff --git a/migration/ram.c b/migration/ram.c
index b4ed41c725..3ac41ccaba 100644
--- a/migration/ram.c
+++ b/migration/ram.c
@@ -812,6 +812,7 @@ static int ram_save_page(RAMState *rs, PageSearchStatus *pss, bool last_stage)
     ram_addr_t offset = pss->page << TARGET_PAGE_BITS;
 
     p = block->host + offset;
+    trace_ram_save_page(block->idstr, (uint64_t)offset, p);
 
     /* In doubt sent page as normal */
     bytes_xmit = 0;
@@ -2614,6 +2615,7 @@ static int ram_load(QEMUFile *f, void *opaque, int version_id)
                 ret = -EINVAL;
                 break;
             }
+            trace_ram_load_loop(block->idstr, (uint64_t)addr, flags, host);
         }
 
         switch (flags & ~RAM_SAVE_FLAG_CONTINUE) {
diff --git a/migration/trace-events b/migration/trace-events
index b8f01a218c..5b8ccf301c 100644
--- a/migration/trace-events
+++ b/migration/trace-events
@@ -69,8 +69,10 @@ migration_bitmap_sync_start(void) ""
 migration_bitmap_sync_end(uint64_t dirty_pages) "dirty_pages %" PRIu64
 migration_throttle(void) ""
 ram_discard_range(const char *rbname, uint64_t start, size_t len) "%s: start: %" PRIx64 " %zx"
+ram_load_loop(const char *rbname, uint64_t addr, int flags, void *host) "%s: addr: %" PRIx64 " flags: %x host: %p"
 ram_load_postcopy_loop(uint64_t addr, int flags) "@%" PRIx64 " %x"
 ram_postcopy_send_discard_bitmap(void) ""
+ram_save_page(const char *rbname, uint64_t offset, void *host) "%s: offset: %" PRIx64 " host: %p"
 ram_save_queue_pages(const char *rbname, size_t start, size_t len) "%s: start: %zx len: %zx"
 
 # migration/migration.c
-- 
2.12.2

  parent reply	other threads:[~2017-04-26 18:37 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-26 18:37 [Qemu-devel] [PATCH 0/2] Postcopy fix and traces Dr. David Alan Gilbert (git)
2017-04-26 18:37 ` [Qemu-devel] [PATCH 1/2] Postcopy: Force allocation of all-zero precopy pages Dr. David Alan Gilbert (git)
2017-04-26 19:00   ` Christian Borntraeger
2017-04-26 19:04     ` Dr. David Alan Gilbert
2017-04-26 19:37       ` Andrea Arcangeli
2017-04-27  3:20         ` Peter Xu
2017-04-27  6:44           ` Christian Borntraeger
2017-04-27 13:47             ` Andrea Arcangeli
2017-04-28 13:19               ` Christian Borntraeger
2017-04-28 14:24                 ` Dr. David Alan Gilbert
2017-04-26 19:52       ` Christian Borntraeger
2017-04-26 19:54         ` Christian Borntraeger
2017-04-26 19:35   ` Juan Quintela
2017-04-27  8:03     ` Dr. David Alan Gilbert
2017-04-26 18:37 ` Dr. David Alan Gilbert (git) [this message]
2017-04-26 18:48   ` [Qemu-devel] [PATCH 2/2] migration: Extra tracing Christian Borntraeger
2017-05-02 13:17   ` Philippe Mathieu-Daudé
2017-05-04  8:40   ` Juan Quintela

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=20170426183721.7482-3-dgilbert@redhat.com \
    --to=dgilbert@redhat.com \
    --cc=borntraeger@de.ibm.com \
    --cc=lvivier@redhat.com \
    --cc=peterx@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=quintela@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.