Multi-Core Scaling In A KVM Virtualized Environment

Written by Michael Larabel in Processors on 15 December 2010 at 10:39 AM EST. Page 1 of 5. 18 Comments.

Earlier this week we published benchmarks comparing Oracle VM VirtualBox to Linux KVM and the Linux system host performance. Some of the feedback from individuals said that it was a bad idea using the Intel Core i7 "Gulftown" with all twelve of its CPU threads available to the hardware-virtualized guest since virtualization technologies are bad in dealing with multiple virtual CPUs. But is this really the case? With not being able to find any concrete benchmarks in that area, we carried out another set of tests to see how well the Linux Kernel-based Virtual Machine scales against the host as the number of CPU cores available to each is increased. It can be both good and bad for Linux virtualization.

This series of tests was again carried out on the Intel Core i7 970 "Gulftown" system with its six physical cores plus Hyper Threading to provide a total count of 12 threads. While Intel’s next-generation products will soon outdo this CPU, the i7 970 has a base frequency of 3.2GHz and a turbo frequency of 3.46GHz. There is 12MB of "Smart Cache" between the cores, support for SSE 4.2, and the latest Intel Virtualization Technology capabilities for providing the best Linux virtualization experience.

The motherboard was still the ASRock X58 SuperComputer, since from its BIOS it allows manipulating the number of enabled CPU cores as well as Hyper Threading, which allows us to easily adjust the number of cores during the testing process. We previously used this for looking at the LLVMpipe scaling performance with the same Intel CPU. Other hardware included 3GB of DDR3 system memory, 320GB Seagate ST3320620AS HDD, and a NVIDIA GeForce GTX 460 graphics card.

For the tests published earlier this week we used Ubuntu 10.10, however, at the request of Red Hat's virtualization group, we switched to Fedora 14 for this testing to represent more a more recent and proper KVM virtualization experience. Fedora 14 x86_64 has the Linux 2.6.35 kernel, GNOME 2.32.0, X.Org Server 1.9.0, GCC 4.5.1, and an EXT4 file-system. Fedora 14 was used on both the host and guest virtualized instance.

To look at the multi-core virtualization performance we tested the system host and KVM virtualized instance when available were 1, 2, 4, 6, and 12 cores. All except for the 12 core testing was done when simply enabling the respective number of CPU cores on the Core i7 970 and then with 12 cores, all CPU cores were enabled plus flipping on Hyper Threading.

The SMP virtual test suite available within Phoronix Test Suite 3.0 "Iveland" was used as our battery of CPU-focused benchmarks to see how well virtualized guests perform and scale to multiple cores. These tests include Apache, a timed compilation process of Apache, C-Ray, CLOMP, 7-Zip compression, PBZIP2 compression, GraphicsMagick, HMMer, NASA NAS Parallel Benchmarks, Smallpt, TTSIOD Renderer, and x264.

Now let us see whether "Virtualization is known to work badly with virtual CPUs" is fact or fiction!

Related Articles