Wow! Microsoft DirectX Adopting SPIR-V Moving Forward

Written by Michael Larabel in Microsoft on 19 September 2024 at 04:19 PM EDT. 110 Comments
MICROSOFT
Well this is a hell of a surprise... Microsoft announced today that DirectX will be adopting SPIR-V as the interchange format of the future. Microsoft's DirectX 12 will accept shaders compiled to SPIR-V, the intermediate representation defined by The Khronos Group and commonly associated with Vulkan / OpenGL / OpenCL drivers.

Today's news has taken me quite by surprise but not entirely unexpected given some progress Microsoft's been making around SPIR-V, doing more around upstream LLVM, opening previously of their DirectX shader compiler, etc. SPIR-V will be effectively replacing DXIL within DirectX moving forward

DirectX adopting SPIR-V


Here are some key takeaways from Microsoft's announcement:
Once Shader Model 7 is released, DirectX 12 will accept shaders compiled to SPIR-V™. The HLSL team is committed to open development processes and collaborating with The Khronos® Group and LLVM Project. We’re sharing this information at the beginning of our multi-year development process so that we can be transparent about this transition from the start. We are working with the Khronos SPIR™ and Vulkan® working groups to ensure that this transition benefits the whole development ecosystem.
...
It is our mission that HLSL be the best language for compiling graphics and compute shaders for any device or GPU runtime API. To support that goal, the HLSL team is actively embracing open technologies and collaborating with industry standards. We will continue to adopt and support the best open-source tools available while contributing our own innovations to make Direct3D and other Microsoft technologies best in class.
...
To better enable HLSL’s Vulkan support, the HLSL team is now participating in The Khronos Group’s SPIR and Vulkan working groups. This direct participation will allow smoother collaboration and more rapid adoption of Vulkan features. We believe this will ensure that HLSL is the best language for writing shaders for every GPU runtime environment.
...
As we look to the future, maintaining a proprietary IR format (even one based on an open-source project) is counter to our commitments to open technologies, so Shader Model 7.0 will adopt SPIR-V as its interchange format. Over the next few years, we will be working to define a SPIR-V environment for Direct3D, and a set of SPIR-V extensions to support all of Direct3D’s current and future shader programming features through SPIR-V. This will allow developers to take better advantage of existing tools and unify the ecosystem around investing in one IR.

In addition to providing a compiler for HLSL to Direct3D’s SPIR-V, we will also be building and providing translation tools to translate SPIR-V to DXIL and DXIL to SPIR-V. Those tools will allow and driver developers to gradually transition and gracefully adapt tooling and drivers.

Read more on the Microsoft DirectX blog.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week