I’ve previously used VirtualBox to run an instance of Delphi in a virtualised environment, but I found the experience was annoyingly slow, the VM took a long time to load up and shut down or go to sleep, and I ended up ditching it to code directly in my main environment.
I can definitely see the benefits of using a virtual environment, but I’m curious: which virtual technology do you recommend if you’re using a virtual environment that works well, and what RAM or other settings have you selected for that environment?
I use Win11 in a VirtualBox VM and don’t have any particular complaints. The only thing I notice is that it takes my a minute longer to get started in the morning and about 40 seconds longer to finish.
My laptop is reasonably high-end though.
i7-12700H 2.30 GHz
1TB and 4TB SSDs.
I’ve allocated 8GB of base memory and run at 1920 x 1080. This allows me to run other VMs at the same time for testing if needed.
I found keeping my VMs on an SSD made a world of difference. I had to add a new drive to my desktop and it has transformed my life.
I use Parallels on my Apple laptop and Hyper-V on a Win 10 desktop. Both work well and have their pluses and minuses. Parallels has really great integration with the host OS and it’s easy to share resources. Tasks for Windows 7 and above run in the Apple’s machine space. (XP VM run as a single task, but I don’t know at which Windows version the they run as seperate tasks.) My Hyper-V VMs seem to run faster but that could be because it’s a desktop with gobs of memory. I’m not sure if Parallels has the same Virtual processor sharing that Hyper-V does, but maybe it doesn’t need to, given that the applications are running as OSX tasks. I do get frustrated that I can’t just plug in a USB to the desktop and nominate which VM or host gets to access it, which can be an issue if you’re developing mobile apps. Overall, I’m happy with both setups.
Vmware Workstation; 3.9GB 4 processors, on an SSD. Auto snapshot has saved my bacon a couple of times with upgrades and component messing about. Been on VMWare for years, so don’t have a good comparison. Snappy enough for me… of course until you are on a zoom or teams call and then EVERYTHING becomes treacle.
I would break it down as follows:
If you are using Windows 10/11 Pro or Server already, HyperV is the best VM for performance, with the only exception being if you need to connect in a physical device like some USB hardware into your development environment. HyperV and VMWare are server grade products and power things like AWS, Azure etc so their Hypervisor is a class above things like Parallels and VirtualBox.
If you can trust your life in the hands of Oracle, or your need physical hardware support whilst losing a little bit of performance, Parallels or VirtualBox would be the other main choices.
When it comes to performance, the following guide will give you the best build speeds:
- Desktop PC’s perform faster than laptops because they generally won’t suffer from thermal throttling. If you are working on large projects you can lose a lot of time with slow compile speeds or slow code insight.
- Almost all the compile/linker processes are single threaded. Be careful to choose a high performing single thread CPU as the industry has done a lot of work adding more cores, but many new chips may not be faster on a single thread. PassMark CPU Benchmarks - Single Thread Performance
- Buy the fastest RAM you can with a motherboard that allows you to run it as fast as possible i.e. enable XMP profiles etc. This makes a big difference to build times.
- Use proper cooling on your RAM and CPU to ensure your CPU doesn’t thermal throttle.
- Use PCI-Express 4 or better with an NVMe Samsung Pro M2 drive. Sustained high performance storage really helps the compiler & linker and in the last few years we’ve gone from 50-100mb/sec with high latency to basically 0 latency and 3-5GB/sec in storage performance.
What a great response - thank you for taking the time to share your insights. Very much appreciated.
This was the missing ingredient that I needed. Thank you Sue. Moving to an SSD massively improved performance. I tested both VirtualBox and VMWare Player…and my conclusion was that VMWare Player is faster than VirtualBox, but the key improvement came from using an SSD.
I have used VMware Workstation for many years with no complaints. The last couple of years I have had my main VM on a Samsung T5 which I switched between my Surface Book 16GB and Surface Studio 32GB. This allowed me to use the desktop computer at home and also develop on the laptop when away from home. Keeping the VM size down can be a bit of a challenge.
I have recently been using the native desktop machine for development work on Windows 11. This was going well until the IDE started taking 2+ minutes to load and start a program in the debugger (F9). A fresh Windows installation is looking like the only cure for that. Or back to the Window 10 VM for the time being.
My last 3 computers have all had SSDs. The latest has 2 in RAID 0. I am waiting to see where a Gen5 PCIe 8TB SSD can be bought to throw into the third slot. Suddenly, reading all these comments, I realise why the Macbook Pro I had prior (with HDD) became so slow.