On 4/19/20 10:06 PM, Wei Wang wrote:
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....@intel.com>
Signed-off-by: Wei Wang <wei.w.w...@intel.com>
---
In addition to Dan's review comments,
+++ b/qapi/migration.json
@@ -70,6 +70,8 @@
#
# @cache-miss-rate: rate of cache miss (since 2.1)
#
+# @encoding-rate: rate of cache miss
This is missing a '(since 5.1)' tag.
+#
# @overflow: number of overflows
#
# Since: 1.2
@@ -77,7 +79,7 @@
{ 'struct': 'XBZRLECacheStats',
'data': {'cache-size': 'int', 'encoded_size': 'int', 'pages': 'int',
'cache-miss': 'int', 'cache-miss-rate': 'number',
- 'overflow': 'int' } }
+ 'encoding-rate': 'number', 'overflow': 'int' } }
##
# @CompressionStats:
@@ -337,6 +339,7 @@
# "pages":2444343,
# "cache-miss":2244,
# "cache-miss-rate":0.123,
+# "encoding-rate":80.1,
# "overflow":34434
# }
# }
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3226
Virtualization: qemu.org | libvirt.org