Currently the live-part (section QEMU_VM_SECTION_PART) of
ram_save_live has only one convergence rule, which is
when the number of dirty pages is smaller than a threshold.
When the guest uses more memory pages than the threshold (e.g.
playing a movie, copying files, sending/receiving many packets),
it may take a very long time before convergence according to
this rule.
This patch (re)introduces a no-progress convergence rule, which limit
the number of times the migration process is not progressing
(and even regressing), with regards to the number of dirty
pages. No-progress means that the number of pages that got
dirty is larger than the number of pages that got transferred
to the destination during the last transfer.
This rule applies only after the first round (in which most
memory pages are being transferred).
Also this patch enlarges the number-dirty-pages threshold (of
the first convergence rule) to 50 pages (was 10)
Signed-off-by: Uri Lublin <address@hidden>