In the secondary side, the colo_flush_ram_cache() calls
migration_bitmap_find_dirty() finding the dirty pages and
flushes them to host. But ram_state's ram_bulk_stage flag is always
enabled in secondary side, it leads to the whole ram pages copy
instead of only dirty pages.

In the test VM with 4GB RAM under the steady state, the
colo_flush_ram_cache() consumes 650 ms.

Here, the ram_bulk_stage flag in secondary side is disabled in the
preparation of COLO incoming process to avoid the whole dirty ram
pages flush.

After patching, the time consumption of colo_flush_ram_cache() is
reduced to 10 ms averagely.

Please help to review and give comments, thanks a lot!


Derek Su (1):
  COLO: only flush dirty ram pages from colo cache

 migration/colo.c |  6 +++++-
 migration/ram.c  | 10 ++++++++++
 migration/ram.h  |  3 +++
 3 files changed, 18 insertions(+), 1 deletion(-)

-- 
2.25.1


Reply via email to