Why does (GNU/)Linux handle memory pressure so much worse compared to macOS and Windows? I can allocate like 50% more than my physical RAM on these systems, and the performance does not tank thanks to swapping to an SSD.
Is this a trade-off between optimizing for latency vs. optimizing for throughput, and Linux chose the latter?
> I disable the swap permanently. It is my personal preference. I hate to see my machine gets slow because it’s starting to swap the data on RAM to disk.
"Rather, I prefer to see it freezing randomly and/or killing random processes, specially the ones likely to be currently holding all the (unsaved) work I did for the last 4 hours."
This is my take too. Instead of disabling it completely, I rather set the swappiness to something low like 10. IMO it's the best of both worlds: I get some memory overrun protection, but it's not used when not necessary.
Is this a trade-off between optimizing for latency vs. optimizing for throughput, and Linux chose the latter?