Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Welcome!

On many computers I experienced poor performance of 32 bit guests running on 64 bit Linux host (I used only the Debian family). At last I managed to collect benchmark data.

I made the benchmark by running custom VBA macro, (which we use in our company) that generates 284 pages long Word document full of Excel Pie charts, tables and comments. The macro is run as a single task (excluding the standard services) on a set of identically configured Windows XP 32-bit systems. I measured the time (in sec.) needed to perform the test.

The computer (i.e. my notebook Asus P53E) supports both VT-d extensions and native Windows XP. It has 2-core processor, each core is hyperthreaded, so in total we have 4 mostly independent execution units.

I use the latest VirtualBox 4.2 and VMWare Workstation 9.0 for Linux, installed together on the same host (running Mint 13 Maya) but never run simultaneously.

The results (in column Time) are no less accurate than ± 10%

Here are the results (sorry for the format, but I couldn't find out a better solution for tables in SO):

+---------------+-------------+------------------------------------------------------+---------+------------+----------------+------+
| Host software | # processor |                    Windows kernel                    | IO APIC | VT-x/AMD-V | 2D Video Accel | Time |
+---------------+-------------+------------------------------------------------------+---------+------------+----------------+------+
| VirtualBox    |           1 | Advanced Configuration and Power Interface (ACPI) PC |       0 |          1 |              0 | 1139 |
| VirtualBox    |           1 | Advanced Configuration and Power Interface (ACPI) PC |       0 |          1 |              1 | 1050 |
| VirtualBox    |           1 | Advanced Configuration and Power Interface (ACPI) PC |       0 |          0 |              1 | 1644 |
| VirtualBox    |           4 | ACPI Multiprocessor PC                               |       1 |          1 |              1 | 6809 |
| VMWare        |           1 | ACPI Uniprocessor PC                                 |         |          1 |              1 | 1175 |
| VMWare        |           4 | ACPI Multiprocessor PC                               |         |          1 |              1 | 3412 |
| Native        |           4 | ACPI Multiprocessor PC                               |         |            |                | 1693 |
| Native        |           1 | Advanced Configuration and Power Interface (ACPI) PC |         |            |                | 1170 |
+---------------+-------------+------------------------------------------------------+---------+------------+----------------+------+

Here are the striking conclusions:

  • Although I've read in the VirtualBox fora about abysmal performance with 32-bit guest on 64-bit host, VMWare also has problems compared to native run, still being twice faster(!) than VBox.
  • Although VBA is inherently single-threaded, the Excel calculations, which take much more than a half of total computation time, supposedly aren't. So one would expect some speed gain when running on 2+ cores ("+" for hyperthreading). What we see is a speed loss. And quite big one too.
  • For the VirtualBox the VT-d extension isn't a big deal.
  • Unless you've got at least 6 independent cores which you are going to use in guest environment, there is performance-wise no point in multiprocessor Windows guest in VirtualBox.
  • Unless you've got at least 3 independent cores which you are going to use in guest environment, there is performance-wise no point in multiprocessor Windows guest in VMWare.

Can anyone shed some light on why the singlethreaded Windows kernel is so much faster than the SMP one?

share|improve this question
add comment

2 Answers

I have noticed hideous performance in virtualbox running 64bit operating systems and I suspect ioapic is the cause and am about to test without, however I want to comment on the SMP kernel issue.

On my laptop I previously had a single core processor, I replaced it with a dual core processor which was from the same generation and same clock speed, the only differences were it has better power saving features and a larger L2 cache size, clocks etc. rest all same. I then discovered after the cpu swap on the old windows kernel performance was ok. I then reinstalled windows, after the reinstallation a APIC kernel was installed and suddenly task manager reported higher cpu usage for the same tasks eg. running task manager took 2% cpu instead of sub 1%. In addition cpu temperatures were higher as if its working harder, very baffling especially as the new install was clean and previous had things like a/v installed. I concluded the same as you that windows has high multi processor overheads. Meaning single processor based apps will run slower on multi core processors.

share|improve this answer
    
Welcome to the superuser! Thank you, for your comment. I feel somewhat honored, that answer to my question is apparently your first experience on this site ;-) –  Adam Ryczkowski Nov 3 '12 at 16:14
add comment

https://www.virtualbox.org/manual/ch03.html#settings-motherboard:

"Enabling the I/O APIC is required for 64-bit guest operating systems, especially Windows Vista; it is also required if you want to use more than one virtual CPU in a virtual machine. However, software support for I/O APICs has been unreliable with some operating systems other than Windows. Also, the use of an I/O APIC slightly increases the overhead of virtualization and therefore slows down the guest OS a little. Warning All Windows operating systems starting with Windows 2000 install different kernels depending on whether an I/O APIC is available. As with ACPI, the I/O APIC therefore must not be turned off after installation of a Windows guest OS. Turning it on after installation will have no effect however."

share|improve this answer
    
Thank you, and welcome on SU! I am aware of this. Note that my x4 slowdown compared to 1 processor "a little" is an understatement, is it? –  Adam Ryczkowski Oct 4 '12 at 20:08
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.