33c38f8ca1
During migrations, after each iteration, cpu_throttle_set() is called, which irrespective of input, re-arms the timer according to value of new_throttle_pct. This causes cpu_throttle_thread() to be delayed in getting scheduled and consqeuntly lets guest run for more time than what the throttle value should allow. This leads to spikes in guest throughput at high cpu-throttle percentage whenever cpu_throttle_set() is called. A solution would be not to modify the timer immediately in cpu_throttle_set(), instead, only modify throttle_percentage so that the throttle would automatically adjust to the required percentage when cpu_throttle_timer_tick() is invoked. Manually tested the patch using following configuration: Guest: Centos7 (3.10.0-123.el7.x86_64) Total Memory - 64GB , CPUs - 16 Tool used - stress (1.0.4) Workload - stress --vm 32 --vm-bytes 1G --vm-keep Migration Parameters: Network Bandwidth - 500MBPS cpu-throttle-initial - 99 Results: With timer_mod(): fails to converge, continues indefinitely Without timer_mod(): converges in 249 sec Signed-off-by: Utkarsh Tripathi <utkarsh.tripathi@nutanix.com> Message-Id: <1609420384-119407-1-git-send-email-utkarsh.tripathi@nutanix.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> |
||
---|---|---|
.. | ||
arch_init.c | ||
balloon.c | ||
bootdevice.c | ||
cpu-throttle.c | ||
cpu-timers.c | ||
cpus.c | ||
datadir.c | ||
device_tree.c | ||
dma-helpers.c | ||
globals.c | ||
icount.c | ||
ioport.c | ||
main.c | ||
memory_mapping.c | ||
memory.c | ||
meson.build | ||
physmem.c | ||
qdev-monitor.c | ||
qemu-seccomp.c | ||
qtest.c | ||
rtc.c | ||
runstate-action.c | ||
runstate.c | ||
timers-state.h | ||
tpm.c | ||
trace-events | ||
trace.h | ||
vl.c |