Linux gaming is faster because Windows APIs are becoming Linux kernel features

xda-developers.com

554 points by haunter 3 days ago


JoeAltmaier - 3 days ago

Used to be a staff member working on an x86 OS called CTOS. I realized if I implemented a couple of traps, we could run command-line DOS programs. So I did. And it worked. Dev tools, text processing, piped commands all worked.

It helped that the DOS executable format was the same as the CTOS format - because we had traded Bill Gates our linker (which produces executables) for his BASIC compiler.

trashface - 7 hours ago

Feels like there is some real momentum on linux gaming now. I mostly play older games but I've gotten most of them working acceptably in proton on my old system 76 laptop (oryp5, with a nvidia 2060; ~7 years old). The laptop actually has plenty of power for the games I play, but I underclock to keep the heat/fan speeds down (been doing the same on the win10 install on the same system), still getting acceptable framerate in proton for most of the things I do in game, non intense stuff.

Decades ago I ported some games to linux but I do think proton is the correct approach now. One underappreciated advantage is you get most of the mod environment too. In ESO for instance, there is an addon (tamriel trade center) which lets you download item prices, but it requires a windows client exe to do that. That client works on proton.

I also do some modding myself and can cross compile my rust code to windows with cargo xwin, and run it right away in proton, which is fairly amusing to behold.

I actually don't mind windows generally (been a MS user since DOS 5), but Win11 is a game changer, pun intended, and not in a good way.

neverkn0wsb357 - 3 hours ago

Given the current momentum, it feels like (to me) the adage of “Windows is for Games” is going by the wayside.

If you look at Steam, and OSs like Bazzite it’s clear the consumer-side is finally shoring up. But that aside, from an economic incentive, game providers (for example Amazon Luna), don’t want to be paying the licenses for running Windows machines for Video Game Streaming on Demand. In fact, at my time there one of the major thing I worked on was figuring out how to stream the games using Linux + Proton + Vulkan so we could use the AMD machines.

Honestly the biggest hurdle was (and probably still is) Anti-Cheat and BattlEye.

At any rate, I’m personally happy to see this trend as I haven’t had a Windows OS since Windows 7.

9x39 - 5 hours ago

Finding a way to get the multiplayer studios to get Linux support for their competitive games like Valve does could crack a wedge in the market for mainstream users to get in, particularly in those who don't want to pay the Windows tax (not everyone is willing to experiment or go unlicensed).

I can't prove it, but the Steam Deck has probably torn down a lot of barriers for mainstream use among the crowd that care about the game more than the OS. Getting some of the other games (League, Vanguard, Warzone, BF6, etc.) or whatever is popular in those segments onboard might be the critical mass that justifies fixing all the rough edges that get fixed when a big pile of users are represented.

Night_Thastus - 7 hours ago

Show me the numbers. Show me an identical gaming PC running Windows 11 and then Linux, and show not just FPS - but things like frametime pacing, latency, etc.

This NTSync stuff is very impressive, but I haven't seen a lot of end-to-end numbers versus Windows. The last comparisons I saw showed pretty much every distribution on the order of 5-30% behind Windows, varying on the game. And Nvidia GPU support was still not great.

I WANT to swap. Please give me cause to do so. I'm sitting here with my finger on the button waiting for it to finally get good enough to make sense.

chromadon - 5 hours ago

I use Bazzite for all my gaming (Returnal at the minute) and it works unbelievably well. I don’t tinker with any of the proton version. I just press play.

I recently completed Stellar Blade with zero issues.

I don’t even shutdown the machine, I just hit the power to sleep it. Instantly resumes where I left off.

Incredible to see just how far it’s come.

zuzululu - 4 hours ago

I support linux gaming btw but I can't help but feel every narrative glosses over that certain games are going to require uncomfortably intrusive anti-cheating systems.

I'm just realizing that I can't play Battlefield 6 and I do wonder what the path is. I don't think it's ever going to be supported on Linux or Mac.

las_balas_tres - 8 hours ago

I developed for windows before moving to linux. I was surprised to find that was no system call similar to windows WaitForMultipleObjects. Sure you can implement something similar using poll() or using condition variables. but WaitForMultipleObjects seems so much simpler and more versatile

Animats - 7 hours ago

There's been real progress. Wine's memory allocator had an architecture with three nested locks. "Realloc" held a futex lock on the memory allocator while recopying the buffer. Multiple threads doing allocation could go into futex congestion, with many threads looping on the futex. This made Vec::push in Rust insanely inefficient. Some of my programs dropped from 60FPS to about 0.5 FPS.

Fixed in Wine 11.0. Thanks to the Wine team.

Not sure if this was related to NTSYNC, but Wine's locking infrastructure definitely got an overhaul.

asveikau - 2 hours ago

This is a fluffy, non-technical article so I googled NTSYNC. It seems like they implement Win32 events, semaphores, mutex and WaitForMultipleObjects.

It's curious that they didn't do this as file descriptors that can be epolled. For example I think you could do semaphores and events with eventfd(2), which always struck me as inspired by those Win32 objects somehow. But maybe this is a simpler purpose built interface.

mifydev - 8 hours ago

I predict that ntsync will eventually evolve into full blown ntoskrnl.ko and there would be virtually no overhead on calling Windows API. You can almost call it a Linux Subsystem for Windows.

tetris11 - 8 hours ago

I wonder what spanners Windows can throw into the works to slow them down at this point, or if they're so checked out of the Desktop market as they suckle down hard on that Azure teat, that they're more than happy to let Linux eat their lunch

bradley13 - 7 hours ago

It's actually been a couple of years since I ran across a game that didn't work well on Linux. At most, I have had to bump the default Proton version.

embeng4096 - 4 hours ago

I switched to Linux for everything but AAA FPS PVP games last year and have had a great experience so far.

Steam+Proton makes everything I play just work: Helldivers 2, Slay the Spire 2, No Rest For The Wicked, FF7 Remake, Stardew, modded Lethal Company (using r2modman) are the main things I've been playing recently, and all worked out of the box with Proton.

My PS5 controller may have needed me to install one package or something but has been working flawlessly after that.

I keep a Windows drive around for stuff like Apex Legends, Battlefield 6, but I pretty much never boot into Windows anymore except for those.

(I probably sound like a shill at this point, having commented something like this on multiple Linux threads now, but I continue to be impressed at how well Linux performs for gaming these days!)

wnevets - 7 hours ago

It may finally be the year of the linx desktop. Microsoft actively being hostile to towards Windows users can't last forever.

0dayz - 2 hours ago

What excites me is that the kernel gets better not only for windows games but can also get benefits that can be more general purpose, such as what the article writes about: program able to wait for multiple events at once.

It will be interesting to see how native Linux games differ in what fancy under the hood kernel or syscall features they use.

caycep - 8 hours ago

If you purpose build a Linux gaming PC, would you lean more towards AMD GPUs over Nvidia?

bsimpson - 8 hours ago

I remember when XDA was the home of Android homebrew hackers working on things like CyanogenMod. It's so strange to see it repurposed as the brand for the same quasi-correct tech article slop that gets parroted between all the big blogs.

Tom's Hardware is a bit before my time, but I remember it being well regarded. I've seen a lot of similar articles under that name lately. I wonder if they've undergone similar fates.

stodor89 - 3 hours ago

Win32 - the #1 stable userland ABI for Linux!

jordigh - 2 hours ago

A great talk at a conference given by Elizabeth Figura, the main developer behind putting NTSYNC into Linux:

https://www.youtube.com/watch?v=NjU4nyWyhU8

h3t08 - 5 hours ago

It’s wild to think that the "Year of the Linux Desktop" didn't happen because of a massive marketing push, but because the kernel just slowly absorbed the competition's DNA.

mattrighetti - 3 hours ago

Seeing XDA brought up some good memories. That's the website that really got me into software engineering. I remember trying thousands of different ROMs every month and changing phone every 6 months. My username is still there and seeing the forum still alive and well is awesome!

mhh__ - 2 hours ago

One canary I have for Linux vs Windows is whether Bloomberg ever support Linux natively on the terminal. You can actually use the API from inside WSL quite easily already.

torginus - 4 hours ago

Personally I don't know if this is some weird compatibility stuff for Windows apps, or the reason why Windows apps on Linux, whether running via Wine or being ports, rely on these apis because no good alternatives exist.. And if these apis are going to be used/useful for stuff beyond Windows compatibility, for native Linux apps.

Which is a weird thing to think about, and not sure very lovely.

tantalor - 6 hours ago

https://store.steampowered.com/hwsurvey/

How do I actually see the graph?

All I see is stats for April:

- Windows 93.47% +1.14%

- Linux 4.52% -0.81%

- OSX 2.01% -0.34%

aftbit - 5 hours ago

Linux gaming is fine unless you want to play something with anti-cheat, which is basically any non-Valve competitive multiplayer title.

Beijinger - 7 hours ago

I found the computer in the article more interesting than the fact, that gaming is getting faster under Linux.

https://www.kickstarter.com/projects/944362954/bapaco-the-wo...

Interesting, but I wish it was half the size folded...

melonpan7 - 7 hours ago

I stopped using Windows all together two years ago, and since then Linux gaming has made huge strides. Almost everything is playable now with the exception of Kernel AC games - which I don’t play anyways. The success of the Steam Deck has been an integral part, and Vulkan performance is similar if not equal to DX.

pluc - 3 hours ago

It can't be neglected that Microsoft is alienating its own power users on such a level that they are now considering switching over and bringing all their know-how with them. Linux gaming is also faster because there's more developers interested in making gaming work outside of the Microsoft dominion.

wwweston - 8 hours ago

I only hope this eventually reaches enough coverage to support media production. It’s the last commercial area I care about. I’m entirely willing to pay for good work here (and have) but both major commercial desktop OSs are exhibiting significant warning signs of contempt for the users.

keithnz - 7 hours ago

my son, and his friends all seem to have switched to https://garudalinux.org/ recently for gaming. Seems to be working out well for them.

andix - 4 hours ago

Time to start betting: Will Windows 12 be based on a Linux kernel? :D

Dwedit - 8 hours ago

Headline says "Windows APIs are becoming Linux kernel features", but only provides two actual examples? It lists NTSYNC, and waiting on multiple events at once.

panzi - 4 hours ago

Is NTSYNC used for anything else other than wine/proton?

gamesbrainiac - 6 hours ago

Anyone move completely over to Linux for gaming? What is the experience like and what are you using?

joaohaas - 2 hours ago

>NTSYNC isn't the first time Linux has gained a new feature specifically because Windows games needed it. A few years back, Linux added a way for software to wait on several events at once, which is something Windows had built in for decades, but Linux didn't.

Lol.

Post doesn't sound explicitly vibewritten, so probably just a non-technical person.

tensegrist - 2 hours ago

"how does it feel to be embraced and extended?"

shmerl - 5 hours ago

ntsync was out already for a while. And it's not necessarily faster than previously available esync and fsync, but it's more correct and clean.

lowbloodsugar - 7 hours ago

This is good to hear, but I get 120FPS on Windows in Cyberpunk 2077 and ~70 on Ubuntu. Horizon Zero Dawn is much worse, and quite often drops to seconds-per-frame instead of frames-per-second, if I turn on dynamic scaling. I just have an ssd with windows on it for gaming and boot to that from the bios. Also means my headphones UI works too. But, to be fair, the fact that I _can_ run Cyberpunk and HZD if I want to is pretty impressive.

torusle - 8 hours ago

Linux does not dragged down in performance by the thousands of virus and malware scanners.

jongjong - 5 hours ago

Crazy to think that it took over 35 years for the superior technical fundamentals to matter.

It's true what Max Planck said that science advances one funeral at a time. So does the tech industry as a whole.

TheRealPomax - 8 hours ago

This page really does not like playing nice with reader mode, making it near impossible to read unfortunately.

everyone - 3 hours ago

The fundamental difference between Linux and OSes like Windows, macOS, Android, iOS, is that the people making Linux are simply trying to make it good, give it as many features as possible, let the user do as much as possible, make it as easy to use as possible.. Whereas the design of the others is guided by a bunch of weird business-goals and internal politics that constantly change.

That's why Linux keeps getting better while the others keep getting worse.

dmvvilela - 7 hours ago

What about macos?

JoheyDev888 - 34 minutes ago

[flagged]

taintlord22 - 4 hours ago

[dead]

fleroviumna - 8 hours ago

[dead]

naikrovek - 3 hours ago

Nothing like copying someone else’s shit when you want to avoid thinking of new things for an operating system.

You could be more like Plan9, Linux. You could actually innovate and create new paradigms that make people look at MacOS and Windows and think that they are no longer in the same league.

But you don’t want to do that. You want to play games faster.

Fucking children run the world today. There are no adults keeping track of things making sure that as we go forward that things make sense. There’s no adult supervision in the computing industry anymore. None. It’s all just profit margins calling all the shots. Asinine.

How did it turn out for windows, being “The OS for Games”? Not great, I’d say. Windows is quickly losing that title and will soon become more and more irrelevant for gaming. If you focus on games until you’re “The OS for Games” then decide to innovate on real things that matter outside the home, then you’ll lose that title just like Microsoft is losing it now, and it will happen a lot faster for you than it did Microsoft, because the Linux community is about as organized as an Oklahoma town recently destroyed by a tornado.

Games are fast enough for anyone and there are certainly enough games today that if 5 people lived for 500 years each, there’s not enough time for them collectively to play all games that are available today.

I don’t know what you gamers think the “end game” is for games. Graphics? When are you meant to be happy? When will you stop and say, “ok, we made it”?

Graphics. Pfft. Games do not get better with more realistic graphics, and you know it. Great games are great because they are well thought out and well tested. Great games are not great because the shadows are sharper or because the reflections are more accurate. Some of the shittiest games ever look amazing, and some of the shittiest looking games are S-tier. And you all know it.

Old man mode: off

ThrowawayR2 - 3 days ago

He who fights with Windows should see to it that he himself does not become Windows. And when you gaze long into ntoskrnl, ntoskrnl also gazes into you.

Seriously, is it really a victory if you have to adopt the architecture of your sworn enemy?