OSDN Git Service

migration: do not flush_compressed_data at the end of iteration
authorXiao Guangrong <xiaoguangrong@tencent.com>
Thu, 6 Sep 2018 07:00:59 +0000 (15:00 +0800)
committerDr. David Alan Gilbert <dgilbert@redhat.com>
Wed, 26 Sep 2018 11:26:58 +0000 (12:26 +0100)
commit48df9d8002914137b0a1e5c4ca4d402224f205f9
treee2f52a4476614544d54234d477480f0ce412e494
parent827beacb474c60b1801399c40ec717c65f9c4e34
migration: do not flush_compressed_data at the end of iteration

flush_compressed_data() needs to wait all compression threads to
finish their work, after that all threads are free until the
migration feeds new request to them, reducing its call can improve
the throughput and use CPU resource more effectively

We do not need to flush all threads at the end of iteration, the
data can be kept locally until the memory block is changed or
memory migration starts over in that case we will meet a dirtied
page which may still exists in compression threads's ring

Signed-off-by: Xiao Guangrong <xiaoguangrong@tencent.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Message-Id: <20180906070101.27280-2-xiaoguangrong@tencent.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
migration/ram.c