qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH v1] migration: using trace_ to replace DPRINTF


From: Philippe Mathieu-Daudé
Subject: Re: [PATCH v1] migration: using trace_ to replace DPRINTF
Date: Sat, 17 Oct 2020 11:57:42 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.3.1

On 10/17/20 11:35 AM, Bihong Yu wrote:
Signed-off-by: Bihong Yu <yubihong@huawei.com>
---
  migration/block.c      | 36 ++++++++++++++++++------------------
  migration/page_cache.c | 13 +++----------
  migration/trace-events | 13 +++++++++++++
  3 files changed, 34 insertions(+), 28 deletions(-)
...
diff --git a/migration/trace-events b/migration/trace-events
index 338f38b..772bb81 100644
--- a/migration/trace-events
+++ b/migration/trace-events
@@ -325,3 +325,16 @@ get_ramblock_vfn_hash(const char *idstr, uint64_t vfn, uint32_t 
crc) "ramblock n
  calc_page_dirty_rate(const char *idstr, uint32_t new_crc, uint32_t old_crc) "ramblock name: 
%s, new crc: %" PRIu32 ", old crc: %" PRIu32
  skip_sample_ramblock(const char *idstr, uint64_t ramblock_size) "ramblock name: 
%s, ramblock size: %" PRIu64
  find_page_matched(const char *idstr) "ramblock %s addr or size changed"
+
+# block.c
+init_blk_migration_shared(const char *blk_device_name) "Start migration for %s with 
shared base image"
+init_blk_migration_full(const char *blk_device_name) "Start full migration for 
%s"
+mig_save_device_dirty(int64_t sector) "Error reading sector %" PRId64
+flush_blks(const char *action, int submitted, int read_done, int transferred) "%s 
submitted %d read_done %d transferred %d"
+block_save(const char *mig_stage, int submitted, int transferred) "Enter save live 
%s submitted %d transferred %d"
+block_save_complete(void) "Block migration completed"
+block_save_pending(uint64_t pending) "Enter save live pending  %" PRIu64
+
+# page_cache.c
+cache_init(int64_t max_num_items) "Setting cache buckets to %" PRId64
+cache_insert(void) "Error allocating page"

The patch is good, but I strongly recommend to have trace events
starting with the subsystem prefix (here migration). So we can
keep using the 'block*' rule to match all events from the block
subsystem, without including the migration events.

Thanks,

Phil.




reply via email to

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