As I have a Hyper-Threading capable CPU, I wonder, is it a bad idea to assign more virtual CPU cores than number of physical CPU cores as the following warning suggests:Transcript:More virtual CPUs are assigned to the virtual machine than the number of physical CPUs on the host system. This is likely to degrade performance of your virtual machine. Please consider reducing the number of virtual CPUs.Can someone put a reasoning to this topic?EDIT1:The CPU in question is Intel Core i7-4700HQ, Ark Intel, CPU BenchmarkEDIT2:Supposing, there is no obsolete HW, like HDD (instead of an SSD), and / or Low RAM (16GB here, minimum vm.swappiness, 4GB for this VM), and so on.
VirtualBox: Is it a bad idea to assign more virtual CPU cores than number of physical CPU cores
virtualbox;virtual machine;performance;cpu;hyperthreading
In my particular case, where the following applies:Host: Linux Mint 18 Cinnamon 64-bit (fully updated); Kernel version 4.4.0-47-genericGuest: Windows 8.1 Pro 64-bit (fully updated)Processor: Intel Core i7-4700HQ, (6MB cache, 4 physical cores, or 8 using hyperthreading),  CPU BenchmarkVirtualBox: Version 5.1.10 r112026 (Qt5.5.1)Guest Additions: Installed and up-to-dateBenchmark Tool #1: WinRAR version 5.40 final 64-bitBenchmark Tool #2: VeraCrypt version 1.19 final 64-bitPreparation: In both cases I waited after boot until the CPU, RAM, disk drive are at stable near zero-point hits.Method:Cloning the original virtual machine to have two identical ones.I have, for the second pass, since the reboot disabled Antivirus pointed out at the bottom of this answer and updated WinRAR in both cases from a Beta to the Final version.I have done the same Preparation as pointed out earlier.The virtual machine ran in foreground, without any other CPU time hungry application running, I have disabled what I could for the purpose of the test not being influenced.To include potential caching inside or outside the system, I ran the same test twice consequently. The benefit being almost none.WinRAR benchmark with 4 cores enabled, 1.5GiB processed in 7.5 minutes:WinRAR benchmark with 8 cores enabled, 1.5GiB processed in 4.5 minutes:I have updated the results, as I forgot to disable Antivirus system both on the host and the guest OS, resulting in more accurate results now.VeraCrypt benchmark with 4 cores enabled, HW-accelerated AES speed 2.6 GiB/s:VeraCrypt benchmark with 8 cores enabled, HW-accelerated AES speed 3.9 GiB/s:I have updated the results, as I, again, forgot to disable Antivirus system both on the host and the guest OS, resulting in more accurate results now.I could run as many tests as necessary. But I figure, if these two, one of which is rather complex compression test, the second being a set of rather complex encryption tests, what would be the point.Conclusion: Both of the benchmarks show a marked difference. I see no reason to believe, that their results are inaccurate, as I followed a rather rigorous preparation and method, moreover these tests have taken place in RAM to rule out I/O bottleneck. From my standpoint, the warning mentioned in the question may apply to some conditions, but certainly not all of them. Having shared with you these pretty remarkable results, I am certain for you to agree with me, that this warning probably should not be taken so seriously on modern CPUs featuring Hyper-Threading with the latest VirtualBox version. One thing for sure: Don't take me for the word and test it under your own conditions, before you decide to apply this setting permanently.