Check out our Monthly Survey Page to see what our users are running.

After attempting for some time now to get their futex2 work into the Linux Kernel, Collabora have cut it all down to focus on one part that has seen thorough testing to help Windows games on Linux with Steam Play Proton.

The work, funded by Valve, is to help Windows game compatibility when they're run through Wine and Steam Play Proton to ensure they actually work and perform well. The current implementations in the Linux Kernel aren't ideal and so they've tried rewriting them. Now they're focusing on adding one specific syscall with "futex_waitv()" so that they "can focus on this operation that already have a well defined use case and has been tested for months now".

Something to note is that this doesn't just benefit games run through compatibility layers, it will also help native games too but obviously with what Valve is doing with the Steam Deck and Proton the focus has been largely on that. In the patches developer André Almeida explained the use case for it as:

The use case of this syscall is to allow low level locking libraries to wait for multiple locks at the same time. This is specially useful for emulating Windows' WaitForMultipleObjects. A futex_waitv()-based solution has been used for some time at Proton's Wine (a compatibility layer to run Windows games on Linux). Compared to a solution that uses eventfd(), futex was able to reduce CPU utilization for games, and even increase frames per second for some games. This happens because eventfd doesn't scale very well for a huge number of read, write and poll calls compared to futex. Native game engines will benefit of this as well, given that this wait pattern is common for games.

If you're interested in the full details you can see the mailing list entry.

Article taken from GamingOnLinux.com.
31 Likes
We do often include affiliate links to earn us some pennies. We are currently affiliated with GOG and Humble Store. See more here.
About the author -
author picture
I am the owner of GamingOnLinux. After discovering Linux back in the days of Mandrake in 2003, I constantly came back to check on the progress of Linux until Ubuntu appeared on the scene and it helped me to really love it. You can reach me easily by emailing GamingOnLinux directly.
See more from me
4 comments

lejimster 11 Aug
Has any of this Futex stuff ever made it upstream? It seems like every year there is some attempt, but it never makes its way into the Kernel.
CatKiller 11 Aug
Quoting: lejimsterHas any of this Futex stuff ever made it upstream? It seems like every year there is some attempt, but it never makes its way into the Kernel.
The kernel cadence is a new version every two months, so more often than that 😝

I can see their point that they want to get their use case sorted for their use case, particularly before December, and they don't want to be bogged down by the kitchen sink nice-to-have stuff that people want, but I hope the design of the changes that get made doesn't prevent the kitchen sink stuff in the future. We don't want to have to have a futex3.
TheRiddick 11 Aug
Think I've been using this with xanmod kernel for a couple weeks now. Had a bumpy start but all seems to work now, I think.
F.Ultra 12 Aug
View PC info
  • Supporter
Quoting: lejimsterHas any of this Futex stuff ever made it upstream? It seems like every year there is some attempt, but it never makes its way into the Kernel.

Yeah zero of them have been accepted so far, this one is very small and nonintrusive though so I'm holding my thumbs.
While you're here, please consider supporting GamingOnLinux on:

Patreon, Liberapay or PayPal Donation.

This ensures all of our main content remains totally free for everyone with no article paywalls. We also don't have tons of adverts, there's also no tracking and we respect your privacy. Just good, fresh content. Without your continued support, we simply could not continue!

You can find even more ways to support us on this dedicated page any time. If you already are, thank you!
Login / Register

Or login with...
Sign in with Steam Sign in with Twitter Sign in with Google
Social logins require cookies to stay logged in.