This may not be your issue, but I see my Windows VM sometimes doing “background” tasks of some sort when it’s been idle for a while. These are visible when starting the Task Manager in Windows, and then choosing the Processes tab and clicking on “Show Processes from all users”. Some of these seem to be search-related, some are anti-virus (not Windows per se), some have unclear purposes (at least to me). So this may just be Windows deciding that your system is idle (after all, the virtual machine is) and taking advantage of the opportunity to run some operating system tasks when they won’t interfere with an active user. Windows seems to be very quick at pausing these tasks once it detects user activity again, which could explain why they stop once you switch back to the VM.
UPDATE: The issue returned! UGH!
I decided to use Parallels Desktop 14 instead. No CPU issues AT ALL!
I was experiencing a similar issue with and without inactivity and landed here; The vmware-vmx process on mac was just going bonkers 250% CPU. I finally got tired of my MBP sounding like a Vacuum and looked into settings I could change.
I'm assumed it was related to the unnecessary Windows 10 animations/graphics - one of the reasons I wish Microsoft had made the WIndows Classic theme available in WIndows 10.
What seemed to fix the memory hogging issue for me was:
1) Disabling Memory Compression (Using Process Hacker as Admin, I noticed a "Memory Compression" process running on my Windows guest):
PowerShell (as an admin) ---> Disable-MMAgent -mc ---> reboot
2) Disabling the unnecessary graphics
Control Panel ---> Set "View by Category" to "Small Icons" ---> System ---> Advanced System Settings ---> ("Advanced" Tab) ---> "Performance" settings --> ("Visual Effects" tab) --> Set to "Adjust to Best Performance", which should uncheck all the boxes --> Apply --> OK
Now the vmware-vmx process on my mac stays around 50%!
I noticed a slight change in the aesthetics after disabling the visual effects, but I can live with them.