aboutsummaryrefslogtreecommitdiff
path: root/monitor
diff options
context:
space:
mode:
authorWei Wang <wei.w.wang@intel.com>2020-04-30 08:59:35 +0800
committerDr. David Alan Gilbert <dgilbert@redhat.com>2020-05-07 17:40:24 +0100
commite460a4b1a4c0e0aeea2c56bfc2407a9a1d1a3ae2 (patch)
treeded96ba444316c96f7c1c6caa4080fd774e67fb7 /monitor
parent59c59c67ee6b0327ae932deb303caa47919aeb1e (diff)
migration/xbzrle: add encoding rate
Users may need to check the xbzrle encoding rate to know if the guest memory is xbzrle encoding-friendly, and dynamically turn off the encoding if the encoding rate is low. Signed-off-by: Yi Sun <yi.y.sun@intel.com> Signed-off-by: Wei Wang <wei.w.wang@intel.com> Message-Id: <1588208375-19556-1-git-send-email-wei.w.wang@intel.com> Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Diffstat (limited to 'monitor')
-rw-r--r--monitor/hmp-cmds.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c
index ade1f85e0c..9c61e769ca 100644
--- a/monitor/hmp-cmds.c
+++ b/monitor/hmp-cmds.c
@@ -303,6 +303,8 @@ void hmp_info_migrate(Monitor *mon, const QDict *qdict)
info->xbzrle_cache->cache_miss);
monitor_printf(mon, "xbzrle cache miss rate: %0.2f\n",
info->xbzrle_cache->cache_miss_rate);
+ monitor_printf(mon, "xbzrle encoding rate: %0.2f\n",
+ info->xbzrle_cache->encoding_rate);
monitor_printf(mon, "xbzrle overflow: %" PRIu64 "\n",
info->xbzrle_cache->overflow);
}