Re:Surprisingly Slow
by vlovich123 on Thursday April 08, 2021 @12:17PM
(#26740608)
It shouldn't actually be a noticeable difference. HW virtualization means that unless the guest is doing I/O or needs to be interrupted to yield to the host, the guest is kind of just doing its thing. Spawning a new user space process in a VM should, in theory, be basically the same speed as spawning a new user space process on the bare metal. How that compares to the WSL1 approach of pico processes I don't know, but Linux generally has a very optimized path for spawning a process that I would imagine is competitive.
I can't say if it's faster relative to WSL2, but I'd guess so. WSL2 is a full VM, after all.
--
[0] - https://docs.microsoft.com/en-us/archive/blogs/wsl/pico-proc...