Stadia Low Change Porting

Earlier this year, at the Google for Games Developer Summit, the Stadia team confirmed what many folks who are familiar with gaming on Linux suspected, Google and developer partners have been using various known techniques to get Windows games running under Linux for Stadia.

Google’s portfolio of techniques involves a continually evolving/maturing set of tools that go under the name of the “Low Change Porting” toolkit.

But, what is Stadia Low Change Porting?

Up to this point, the main ingredient of this toolkit appears to be “DXVK” – in particular, “DXVK-native.” In, Marcin Undak’s talk (at the Google for Games Developer Summit), he says:

The Stadia Porting Toolkit is a set of source-code libraries that help in translating Windows APIs to Linux. For example, we use DXVK to implement DirectX APIs; so, developers don’t have to modify their game rendering at all.

DXVK is essentially a tool that let’s developers targeting Linux + Vulkan skip a big chunk of the work in bringing their games over by translating DirectX 9-11 API calls (and a small amount of related Windows APIs) to Vulkan and LInux API calls. It is an open source project that saw its first official public release in August, 2021 – and has been used by Valve for it’s own projects as well as various teams bringing games to Stadia.

It appears that (likely among others) Metro Exodus, Ys VIII, Ys IX, Trails of Cold Steel III + IV all used DXVK-native to bring their games to Vulkan and Stadia. Stadia has adopted this approach officially in their porting toolkit according to Marcin.

It’s important to note that there is nothing about using DXVK-native that makes supporting future updates to games more difficult than if a separate Vulkan branch of the game were created. On the contrary, it likely reduces the amount of separate code needed to be maintained for games/engines that are designed for DirectX first.

What’s Next?

What’s coming in the future is likely to be the equivalent for Stadia of what “Proton” is for Steam – allowing windows games to run essentially modified – with the exception perhaps of implementing Stadia specific API calls.

It is important to note that Proton is not something Valve developed from scratch. It is essentially just a fork of WINE, an opensource community project that has allowed Windows apps and games to be run on Linux for decades! I used WINE to play Elder Scrolls Oblivion and Half Life 2 flawlessly on my Linux box back in the 2000s.

Proton packages WINE, DXVK (and the DirectX12 equivalent VKD3D) together along with some Steam-isms to enable Steam Windows games to run on on Linux.

Again at this years Google for Games Developer Summit, we learned Google is working on putting together a software stack that is roughly the equivalent of this – but, while also considering using WINE for their own purposes, they were also exploring creating their own WINE “light” like framework to handle the windows system calls that are needed by games (note WINE itself is a pretty bloated beast because it needs to run Microsoft Office, Photoshop and a plethora of other complex Windows apps that WINE users want to execute on Linux).

A windows game typically relies on (1) Windows system calls for various purposes (e.g. accessing storage, managing tasks etc.), (2) DirectX calls for GPU acceleration and (3) some platform SDK/API for things like friends lists, achievements etc.

To get an unmodified Windows game to run well in Linux, you need to provide these three things.

It’s my guess that future iterations of the low change porting toolkit will package all three of these pieces together in a way similar to “Proton” but in Google’s own style and with a performance and cloud-centric focus in tow.

Jack Deslippe

Jack Deslippe is an HPC professional with a PhD in Physics from the University of California, Berkeley. As a hobby, he is passionate about consumer technology and Cloud Gaming in particular. He volunteers as an editor for Cloud Dosage in his spare time. See the games Jack is Playing at ExoPhase. Like his content? You can follow Jack on Threads: @jackdeslippe and Buy Jack a Beer.

Leave a Reply