Hello, I am considering a MacBook for mostly programming and some VM tasks. The two devices I am eyeing are the following:
MacBook Pro 14-inch - M2 Max 12/30 cores - 32 GB ram - 1 TB for $1899
MacBook Pro 14-inch - M4 Pro 12/16 cores - 24 GB ram - 512 GB for $1799
They are both in New condition.
Which machine would you recommend getting for my needs?
How big are your VMs and do you plan to run them locally (as in, on internal storage)?
In my experience; with comfortable space for data, applications and a reasonable size Windows VM - 512 GB will be insufficient storage. I did it 8 years ago and even then 512GB was getting tight. Running a machine at 80% plus capacity all the time will increase wear on the SSD as it can't do wear levelling, leave you little free space for temporary use, local backups, VM snapshots, etc. So work out how much data you expect to store, multiply by 1.5 and buy something that size or larger to allow for swing space and some growth.
1GB will be "enough" but maybe tight these days (my previous machine), 2 TB will probably be plenty - but I don't know the size of your specific data. RAM wise, 12GB for a Windows VM is comfortable for day to day stuff but it really depends what apps you plan to run in it.
I did similar with 16GB of RAM and 1TB on my M1 Pro (8 GB windows VM, windows struggled bit from time to time) - but these days I'd suggest 32 GB and 1TB or as much storage as you can reasonably afford. The M-Pro and M-Max machines are still pretty responsive even when you start running into swap/orange memory pressure with virtual machines though.
Whether you need the Max CPU or not will depend highly on what you plan on running on the machine both in and out of the VM; if you want high end graphics that may push you to max. If you want more than 32 GB of RAM you may be pushed to max as well. I wanted 64 GB of RAM in my M4 so max was the only option for me this time around.
For the two machines you mentioned, IMHO the M4 just won't have enough storage to be comfortable unless you plan on running VMs from an external SSD (if not out of the box, eventually when you run out of space). Windows is at least say, 60 GB, plus apps, plus snapshots to roll back to, etc.
If those are the only two choices, I'd go for the M2 Max.
If you're willing to go a little older and be prepared to upgrade again in a couple of years (i.e., either before or when the M1 series goes end of support, if that matters to you), keep an eye out for a high spec M1 Max - they're getting cheap now as a lot of people are upgrading from M1 generation to M4, and they're still a potent machine. You'll be able to get more Ram and more storage for less money. And for your workload, RAM and storage is probably going to be the limiting factor.
The M1 Pro/Max is still a pretty quick machine CPU wise, even by today's standards. I upgraded from M1 Pro to M4 Max, but the reasons were storage space and GPU related for AI/games/etc. to replace my desktop PC (as I spend less time gaming now anyway). CPU wise it was still super responsive. M2/M4 pro will be even better.