ping: Re: [PATCH] cpu-throttle: Fix vcpu missed throttle work

2023-09-19 Thread alloc young
Hi pbonzini: please take some to review this patch. It fixes autoconverge migration issue for heavy memory dirty pages. Any comment will be welcome, Thx. On 2023/9/18 11:29, alloc.yo...@outlook.com wrote: From: alloc During migrations, vcpu may run longer than 10ms and not exit on time.

[PATCH] cpu-throttle: Fix vcpu missed throttle work

2023-09-17 Thread alloc . young
From: alloc During migrations, vcpu may run longer than 10ms and not exit on time. If the vcpu runs over 20ms, then it'll miss a throttle kick and will run the whole tick. When this happens and vcpu dirties pages fast, the migration will take long time or event not enable to auto converge. To

Re: [PATCH] softmmu/dirtylimit: Fix usleep early return on signal

2023-09-07 Thread alloc young
On 2023/9/4 21:27, Yong Huang wrote: On Fri, Sep 1, 2023 at 10:19 AM > wrote: From: alloc mailto:alloc.yo...@outlook.com>> Timeout functions like usleep can return early on signal, which reduces more dirty pages than expected. In dirtylimit

Re: [PATCH] softmmu/dirtylimit: Fix usleep early return on signal

2023-09-04 Thread alloc young
On 2023/9/4 21:27, Yong Huang wrote: On Fri, Sep 1, 2023 at 10:19 AM > wrote: From: alloc mailto:alloc.yo...@outlook.com>> Timeout functions like usleep can return early on signal, which reduces more dirty pages than expected. In dirtylimit

[PATCH] softmmu/dirtylimit: Fix usleep early return on signal

2023-08-31 Thread alloc . young
From: alloc Timeout functions like usleep can return early on signal, which reduces more dirty pages than expected. In dirtylimit case, dirtyrate meter thread needs to kick all vcpus out to sync. The callchain: vcpu_calculate_dirtyrate global_dirty_log_sync

[PATCH] accel/kvm: Fix dirty reaper thread crash

2023-08-28 Thread alloc . young
From: alloc kvm_dirty_ring_reaper_init is called much early than vcpu creation, so it's possibe the reaper get a crash before vcpu mmap kvm_dirty_gfns. Add a machine done notifier to ensure dirty reaper get run after vcpu inited. Signed-off-by: alloc --- accel/kvm/kvm-all.c | 9 +++-- 1

[PATCH v2 0/2] softmmu/dirtylimit: Fix memory leak issue

2023-08-24 Thread alloc . young
From: alloc Changes in v2: - Split into two patches, one fixing memory leak issue and another converting free to g_free. - Fix typos alloc (1): softmmu/dirtylimit: Convert free to g_free alloc.young (1): softmmu: Fix dirtylimit memory leak softmmu/dirtylimit.c | 26

[PATCH v2 2/2] softmmu/dirtylimit: Convert free to g_free

2023-08-24 Thread alloc . young
From: alloc Convert free to g_free to match g_new and g_malloc functions. Signed-off-by: alloc --- softmmu/dirtylimit.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/softmmu/dirtylimit.c b/softmmu/dirtylimit.c index e3ff53b8fc..fa959d7743 100644 ---

[PATCH v2 1/2] softmmu: Fix dirtylimit memory leak

2023-08-24 Thread alloc . young
From: "alloc.young" Fix memory leak in hmp_info_vcpu_dirty_limit,use g_autoptr to handle memory deallocation. Signed-off-by: alloc.young --- softmmu/dirtylimit.c | 16 +++- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/softmmu/dirtylimit.c b/softmmu/dirtylimit.c

Re: [PATCH] softmmu: Fix dirtylimit memory leak

2023-08-24 Thread alloc young
On 2023/8/24 13:16, Michael Tokarev wrote: 23.08.2023 10:47, alloc.yo...@outlook.com wrote: From: "alloc.young" Fix memory leak in hmp_info_vcpu_dirty_limit,use g_autoptr handle memory deallocation, alse use g_free to match g_malloc && g_new functions. "..use g_autoptr TO handle.." ("to"

[PATCH] softmmu: Fix dirtylimit memory leak

2023-08-23 Thread alloc . young
From: "alloc.young" Fix memory leak in hmp_info_vcpu_dirty_limit,use g_autoptr to handle memory deallocation. Signed-off-by: alloc.young Reviewed-by: Yong Huang --- v1->v2 drop g_free, just focus on fix memory leak issue --- softmmu/dirtylimit.c | 16 +++- 1 file changed, 7

[PATCH] softmmu: Fix dirtylimit memory leak

2023-08-23 Thread alloc . young
From: "alloc.young" Fix memory leak in hmp_info_vcpu_dirty_limit,use g_autoptr handle memory deallocation, alse use g_free to match g_malloc && g_new functions. Signed-off-by: alloc.young --- softmmu/dirtylimit.c | 26 -- 1 file changed, 12 insertions(+), 14