[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] Disparity between host and guest CPU utilization during dis
From: |
Nagarajan, Padhu (HPE Storage) |
Subject: |
[Qemu-devel] Disparity between host and guest CPU utilization during disk IO benchmark |
Date: |
Mon, 10 Jul 2017 17:27:15 +0000 |
Posted this in qemu-discuss and did not get a response. Hoping that someone
here might be able to offer insights.
I was running an 8K random-read fio benchmark inside the guest with iodepth=32.
The device used inside the guest for the test was a virtio-blk device with
iothread enabled, mapped on to a raw block device on the host. While this
workload was running, I took a snapshot of the CPU utilization reported by the
host and the guest. The guest had 4 cores. top inside guest shows 3 idle cores
and one core being 74% utilized by fio (active on core 3). The host had 12
cores and three cores were completely consumed by three qemu threads. top
inside host shows three qemu threads, each utilizing the CPU core to a near
100%. These threads are "CPU 1/KVM", "CPU 3/KVM" and "IO iothread1". The CPU
utilization story on the host side is the same, even if I run a light fio
workload inside the guest (for ex. iodepth=1).
Why do I see two "CPU/KVM" threads occupying 100% CPU, even though only one
core inside the guest is being utilized ? Note that I had 'accel=kvm' turned on
for the guest.
Why does the CPU/KVM thread on the host use 100% CPU, even though the
corresponding guest core utilization is far less ?
The host operating environment was Debian 8 and the guest was CentOS 7.3. I was
running qemu-2.8.1 on the host. The guest VM had 'accel=kvm' turned on. The CPU
utilization snapshot from 'top' on host (left) and guest (right) at the same
point in time can be found here: https://ibb.co/ho3q0F
~Padhu.
host_guest_cpu_util.jpg
Description: host_guest_cpu_util.jpg
- [Qemu-devel] Disparity between host and guest CPU utilization during disk IO benchmark,
Nagarajan, Padhu (HPE Storage) <=