Hacker News new | ask | show | jobs
Ask HN: Mac OS vs. Windows in 2022
7 points by kujin88 1385 days ago
Not talking about the hardware, but the general experience overall. I know Windows has gotten a lot better with WSL these recent years, but I haven't touched Windows for 10 years now. Peeps here who have had experience with developer-friendliness and tooling in both these platforms, can you comment?

Thanks a lot!

9 comments

As a general purpose OS, I actually quite like Windows 11, its nice, clean, and beautiful. But unfortunately, Windows is not there for development. I've used WSL for years and its actually gotten much worse with WSL2, especially with Docker. Specifically, I'd be plagued by this issue (https://github.com/microsoft/WSL/issues/4166), where Docker would eat all the WSL memory and never release it. I finally pulled the plug and use Ubuntu 22 as as a daily OS (on dual boot), the UX is not bad, e.g. I was actually pleasantly surprised by the smoothness of the windowing gestures as a first time user, but there are many warts (e.g. very janky around sleeping/hibernating). I mostly develop and browse the web so its OK overall.

MacOS is very good, no real complaints.

Thanks for the insight. Regarding the memory problem, how about installing massive amounts of Ram? It's cheap and a lot of laptops outside the Apple realm have open memory slots
re the memory, More RAM won't help, the bug was that docker would eat all the memory you give it. The mitigation was to limit your WSL memory.
Ubuntu has been better than McOS in my experience.

When there are issues, at least you can search and resolve them.

I honestly hate both. On macos, I need 3 utility apps just to make the desktop windows behave / layout / switch in a reasonable way. Advanced firewall and permission control basically doesn't exist. If you compile lots of software, you'll occasionally find things that fail for very Mac-specific reasons. At least it's a posix-ish system, so many Linux tools can be compiled natively. But if you use homebrew as a developer, prepare for occasional breakages.

On Windows, the lack of packages and automatic updates running as an extra app for everything is absurd at this point. (Yes, winget is getting there and can be usable if you know about it and your apps support it) Each device driver thinks it's a marketing opportunity for the producer with yet another tray bar entry. Start search sucks every time (I'm told it's fixed in win11). WSL2 exists, but it's just a vm with nice tooling. Constant marketing spam that comes back after you disable it in a product you paid for. Failing updates.

Edit: Also, both have a layer below which debugging is extremely hard. Why did something fail? Haha, good luck, we'll just log "Operation: failed", hope you like dtrace and digging into the kernel to solve it.

So, I'm not recommending either. Macos is less bad due to posix-ish environment. Happy Linux user.

I despise shitting on either OS.

I highly recommend macOS with vmware fusion to run/integrate windows and linux VMs.

Mac is too apple lockeddown, strict and opinionated on trivial things, Linux is fragile and messy, windows is somehow over and under-engineered at the same time with legacy crap holding it back.

They all suck and rock depending on perspective so use them all on the same device (macbooks are solid), alternating between them to take advantage of their nice features and avoid the bad stuff.

I use macOS (as my main/dev laptop), W10 laptop for some work stuff, and various Linux flavour headless servers (RPis and cloud). And I have used many many OSes in the past, including many variants of nix and Windows.

I had never managed to get a nix laptop install to work nicely, including ma ny attempts with Solaris for example. That's what I get out of the box with macOS, and with decent nix tools support. Plus Homebrew is good!

W10 is the best Windows environment that I have used, and the Linux subsystem works reasonably well for me. But is is SLOW*. I think that there's something like a 2x CPU tax to run Windows in practice, and I've definitely repeatably measured consistent performance penalties for Windows over other OSes on the same hardware for my clients in the past.

I do pay a hefty premium for macOS, but it generally just does work more reliably and faster and more smoothly than Windows, for me, so I pay it willingly.

Thanks! >>> I've definitely repeatably measured consistent performance penalties for Windows over other OSes on the same hardware

Not sure about the deal here though, I have a really high-grade Macbook Pro at work and it is always, always constantly noisy and heating up with something as simple as compiling a medium-sized Java project.

Whatever any of the fanbois will tell you, no OS or machine is perfect!

I also put a fair amount of time into tuning my build systems to be efficient, which can help with the kind of (very real) problem you mention.

An unexpectedly nice feature of my MBA M1 is no fan noise at any time. I long ago switched all my other machines to fanless, eg so that they could run overnight quietly, but my laptop never making fan noises is good!

Windows is a dumpster fire

macOS is the way to go if you want to get shit done, native linux env, smooth OS, fast file system

battery life and perf/watt is unmatched

the fact that microsoft had to ship a whole VM speaks volume about what you need nowadays to function: a proper linux env

about WSL: it's awfully slow

> native linux env

What did you mean by this?

> about WSL: it's awfully slow

Uh... it's equally as fast as emulating a Linux kernel on MacOS. MacOS does not support Linux programs natively (or Linux-based Docker containers). It's kernel is not Linux-based, it's commands are not Linux-equivalent. Only BSD-based software has a native compatibility layer, and even that is notoriously hit-or-miss.

I was under the impression that WSL2 runs on the actual hardware with only the hypervisor as overhead, and so it should run nearly as fast as the real thing. I haven't noticed particularly slow performance, but it could just be that I haven't looked into it enough.
WSL 2 itself is fast but any GUI tooling around it is slow. Vscode for example needs to start a remote server inside wsl to do anything.
` about WSL: it's awfully slow `

But as far as I remember, something like WSL isn't even possible on a Macbook, right?

Can you elaborate on what makes Windows a dumpster fire? Windows 11 looks promising

Why bother emulating running Linux (and badly at that) when you can run native Linux? Try something like PopOS... If you don't game its great.
> Why bother emulating running Linux (and badly at that) when you can run native Linux?

Because many people want to get their work done, instead of playing around with the desktop environment, dotfiles, package managers or diagnosing / googling why their distro upgrade failed or why an app isn't working with Wayland, inconsistent global keyboard shortcuts and trackpad issues on laptops or whatever.

It's trillions of hoops for Desktop Linux to get to the consistency and equivalent working state of macOS just to get work done and many users view Linux Desktop as a piece of work in itself to get to the equivalent full supported state of Windows, hence why they emulate a Linux Desktop instead with WSL, rather than migrating files, clean installing, downloading poor app replacements and dual booting a Linux desktop.

Little to no-one has the time to try out the tons of distros or even migrate all their files and clean install for something that works less than macOS, or Windows.

> It's trillions of hoops for Desktop Linux to get to the consistency and equivalent working state of macOS

Of course it is, nobody should be making MacOS with free software. To get to the equivalent working state of MacOS, we'd have to remove the package manager, add a first-party app store, add in OSCP surveillance/telemetry, remove OpenGL/Vulkan support, remove 32-bit libraries, axe the Nvidia drivers and close all contributions to the kernel. That will always be impossible, it's by design.

> To get to the equivalent working state of MacOS, we'd have to...

As if anyone told you all of that was the hard requirement for just a consistent Linux desktop.

It's an evergreen unsolvable problem for the Linux desktop ecosystem (not servers) to even point to and get behind a sane Linux distro that offers a similar integrated and consistent desktop environment to Windows and macOS whilst being free and open source which developers can simply just reference and build against and just use, rather than reverting to the closed source alternatives, because of the many Linux desktop issues.

> That will always be impossible, it's by design.

Yeah. Alternatives of alternative system contraptions with multiple combinations of bugs and hunting them up and down the Linux Desktop stack is great design! /s.

Proving my point and admitting the failure of the Linux Desktop and how 'terrible' it is and why even the majority of developers here also admitted that they don't even recommend using it as their daily driver for a dev environment.

I don't think you've done anything except prove my point. It's okay to express anger that you can't use a free OS, but plenty of other people do. It's perfectly fine for development, and you've done nothing to refute the idea that Linux is a great platform for developers. If you're going to keep moving the goalpost (remember: OP wanted something developer-friendly, not user-friendly) then we're not going to be able to engage in legitimate discussion.
> I don't think you've done anything except prove my point. It's okay to express anger that you can't use a free OS, but plenty of other people do.

I guess your denial is that (even when the OP asked here) the majority of developers are using either Windows, and macOS instead of a Linux Desktop to get their work done as I have repeatedly explained.

> It's perfectly fine for development, and you've done nothing to refute the idea that Linux is a great platform for developers.

Except that wasn't the OP's question. They are talking about the host platform to develop ON and not the TARGET. Even when asked, the respondents say otherwise; even when the intended target is Linux.

> If you're going to keep moving the goalpost (remember: OP wanted something developer-friendly, not user-friendly) then we're not going to be able to engage in legitimate discussion.

There is no goalpost being moved. The OP gave a simple question on which host platform to develop ON and more respondents commented about their desktops or laptops running Windows with (WSL2) or a typical macOS setup. Since you already admitted that 'the Linux Desktop is terrible' and given the responses in this post, it is clear that it already has disqualified itself as a suitable host platform to develop on.

Furthermore, proving my evergreen point for the Linux Desktop:

If they cannot use the desktop then it is pointless to recommend it as a 'developer-friendly environment' or even begin clean installing it just for a worse desktop experience for the developer, which for GUI desktop apps, there are little to no users to target compared to the likes of macOS and Windows.

What systems have you used desktop Linux on, and how long ago? On most modern systems I've recently used it on, right out of the box it's worked as well as Windows and macOS do.
Linux was my first choice, however I keep running into issues with Sleep/Hibernate with an nVidia discrete GPU on my laptop;

And Optimus seems to be bothersome with requiring constant restarts and hassle.

If you think grass is greener on the other side, Windows 10 has serious issues where it randomly doesn't sleep and just drains the battery, and macos may keep waking up every few minutes to run background tasks even though you explicitly configured it not to. Out of the 3 systems, my Linux one with discrete nVidia is the one that always handles sleep well.
you may refer to

> Out of 130 tests in total, Windows 11 WSL2 Ubuntu 20.04 LTS managed to run at 94% the speed of bare metal Ubuntu 20.04 LTS on the same system.

from Phoronix https://www.phoronix.com/review/windows11-wsl2-good/5

Both Windows and macOS are good, the Linux desktop in 2022 however is just woeful.
Beg to differ here, I've been on Linux Desktop for 10 years now and used a ton of "major distros" like KDE Neon, Manjaro, Mint, and Zorin etc. All of them were incredibly solid with full driver support (AMD CPU) and stable on my PC.
That's the point. Little to no users have the interest in wasting time distro-hopping for 10 years just to use a computer to get work done and it has nothing to do with 'full driver support' which that is a given and is the bare minimum.

Windows and macOS have full integration, high consistency and developers support one type of OS for their apps to test and that is it. Now with WSL2, there is no need to dual boot or format, re-install a Linux Desktop after a failed distro upgrade / conflict and this fully works inside of Windows.

Also, 1 anecdote from 1 user isn't remotely sufficient evidence.

> Both Windows and macOS are good, the Linux desktop in 2022 however is just woeful.

[ ...one comment later... ]

> 1 anecdote from 1 user isn't remotely sufficient evidence.

I hope I don't need to point out the hypocrisy here.

I'd also tear apart the idea that MacOS/Windows present "one target" to build for, but I don't need to. You already concede that WSL2 is needed to make Windows a viable development environment, at which point you can cut out Windows altogether and just use the development environment side of things. Same goes for MacOS, if you're only relying on the development toolchain, then there's no reason to use the poorly-supported Darwin kernel in the first place. Linux is a terrible desktop, but as an operating system it's purely magnificent. It's become the industry standard for good reason.

> I hope I don't need to point out the hypocrisy here.

I don't think you have finished reading all the comments around this whole 'Ask HN' post with more comments here recommending either 'Windows', and 'macOS' over 'Linux' as their 'main desktop' to develop 'on'.

> You already concede that WSL2 is needed to make Windows a viable development environment.

Now where did I say that?

WSL2 isn't used for targeting desktop apps for Windows, it is used for developers that want to easily target Linux or testing their apps on Linux by NOT going through the process of clean installing, dual booting, migrating files to an entire separate Linux desktop environment to do that, which that is the use-case to run both Windows as the main system and Linux as the guest.

With this one can easily develop or test and target typical desktop apps on a Windows machine without switching, dual booting, etc which is what I am talking about and the same is true for macOS which developers use to target for macOS desktop apps.

So you have a more integrated consistent developer / desktop experience where the desktop works with the developer rather than the developer wasting time fighting with their computer and they end up distro-hopping for years rather than getting work done.

> Linux is a terrible desktop...

That is all the OP needs to know. Everything else beyond that sentence is irrelevant.

If they cannot use the desktop then it is pointless to recommend it as a 'developer-friendly environment' or even begin clean installing it just for a worse desktop experience for the developer, which for GUI desktop apps, there are little to no users to target compared to the likes of macOS and Windows.

> I don't think you have finished reading all the comments

I wasn't responding to all of the comments. I was responding to you.

> With this one can easily develop or test and target typical desktop apps on a Windows machine without switching, dual booting, etc

That was totally possible before. VM passthrough works fine, (even "natively" with VMWare's software), and mingw is perfectly capable of native cross-compilation. WSL is neat, but it's not any more advanced than what Chromebooks have had for years. Hell, it's barely more impressive than MacOS' POSIX compliance.

> there are little to no users to target compared to the likes of macOS and Windows.

You can cross-compile MacOS and Windows apps on Linux just fine (done it many times before). Of course, you can also target webdev and mobile devices, as well as Docker, Kubernetes and other service-oriented software. But you're right, writing Fart Simulator for iOS is where all the real money is. I'll defer to your opinion rather than the thousands of people on this very site making money off headless Linux servers.

> That is all the OP needs to know.

Sure, if they don't want to write system services, self-hosted websites, self-custody backends, databases, Kubernetes clusters, CI/CD pipelines, Docker containers or test DevOps services locally, then that is all they need to know about Linux. They should focus on the actual breadwinners, like getting their 70% from the App Store.

>>>wasting time distro-hopping for 10 years

I wouldn't assume so about others. Those 10 years were super productive for me actually. I switched distros merely because I wanted to experience others out of my own will. My Desktop had no problems with any distro but my laptop does seem to have driver issues.

I am only looking to know how good the Wsl part inside the new Windows is. I use a Mac at work and it never impressed me but I can get my work done on it

I bounce between WSL2 running on windows 10 and an M1 mbpro max.

TL;DR is buy an M1/M2 Mac if you want to buy a laptop. I like both setups, but only because I’m done jumping through most of the wsl hoops.

If you go with windows, be sure to use Windows Terminal as all other terminals I’ve used (haven’t tried hyper) suffer performance-wise with wsl.

The biggest issue with wsl is easily the memory usage. No one seems to talk about this part of wsl, but if you use vscode, you’ll quickly fill up 16gb of ram while also doing things like running discord/slack + a dozen chrome tabs. I’ve since transitioned to (neo)vim and the experience is much better RAM-wise. Bare minimum for any windows computer running wsl is 32gb imo, especially if you’re using any amount of docker like that other comment mentioned. I ended up having to write a cronjob to manually clean up terminated containers still hogging memory periodically.

This brings me to another downside of wsl: just by having wsl on, it will take about 2gb minimum in my experience. This is unfortunate, as the only way to run the cron server in wsl on windows startup is to have windows task manager turn it on at startup, essentially forever hogging a minimum amount of ram on your machine. I play lots of games on my windows machine and it feels very clunky to have to always open power shell and run `wsl —shutdown` before I can play games. An unfortunate tradeoff between the wsl cron server, and anything else you’d ever like to do that requires significant memory.

Personally I think any sort of Mac desktop is silly (just get a powerful m1/m2 and external display(s), although be careful of the new m2 which only supports 1 external display iirc) and after using both of these machines/dev environments extensively, I can say that if I had to do it again I’d just go with a Mac laptop. If you have the funds I strongly recommend doing the same. However, if you’d like a pc for anything windows specific (like most games), wsl is a fine choice so long as you get an appropriate amount of ram and don’t mind the extra time/energy required for debugging some wsl specific issues. Most wsl issues are one time things that don’t take too long, but it definitely takes some getting used to.

Also worth noting that something I’ve found to be annoying about wsl is that there’s so few resources online for debugging issues when compared to the mac ecosystem. Not only that, but if you change your distro from the default Ubuntu in wsl, the set of people running into similar issues will be even smaller.

To add to my ramblings, I had issues setting up an xserver for a wsl gui and eventually just gave up.

One of the new Mac’s will just work out of the box.

Hope this helps you make your decision.

Thank you. Really well written and appreciate the insight. Regarding m1 macs, I see that people seem to be doing a lot of housekeeping trying to tie things together back again.

Since the arm CPU is still new to a lot of apps/tooling, people are not left with much, other than some workarounds and hacks that will serve as a stop-gap solution for a lot of things.

I'm worried about this as well and wondering how much is this has been true in your case! Thanks!

A valid concern. My experience is that by now, most apps/projects have support for m1 Mac’s out of the box. For the minority that don’t, I always find a solution that fits nicely in the first gist shown by google. I honestly don’t even consider it to be an inconvenience when I hold it up next to my experience with wsl. Not to mention that the support for new Mac architecture will only continue to improve + be a priority given the market share.

Don’t forget that even if you somehow run out of avenues for support on a mac, you can always dual boot linux on it. You could probably even bootcamp a mac to run windows and then run wsl inside it (I’m kidding but you get the point).