{"id":18782122,"url":"https://github.com/gpuopen-librariesandsdks/directxshadercompiler","last_synced_at":"2025-07-14T15:07:06.621Z","repository":{"id":258703312,"uuid":"873250563","full_name":"GPUOpen-LibrariesAndSDKs/DirectXShaderCompiler","owner":"GPUOpen-LibrariesAndSDKs","description":"Mirror of https://github.com/microsoft/DirectXShaderCompiler","archived":false,"fork":false,"pushed_at":"2024-10-17T12:14:50.000Z","size":66565,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-05-21T07:47:40.355Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/GPUOpen-LibrariesAndSDKs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.TXT","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-10-15T21:09:32.000Z","updated_at":"2025-02-23T10:26:56.000Z","dependencies_parsed_at":"2024-10-20T07:50:21.306Z","dependency_job_id":null,"html_url":"https://github.com/GPUOpen-LibrariesAndSDKs/DirectXShaderCompiler","commit_stats":null,"previous_names":["gpuopen-librariesandsdks/directxshadercompiler"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/GPUOpen-LibrariesAndSDKs/DirectXShaderCompiler","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GPUOpen-LibrariesAndSDKs%2FDirectXShaderCompiler","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GPUOpen-LibrariesAndSDKs%2FDirectXShaderCompiler/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GPUOpen-LibrariesAndSDKs%2FDirectXShaderCompiler/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GPUOpen-LibrariesAndSDKs%2FDirectXShaderCompiler/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/GPUOpen-LibrariesAndSDKs","download_url":"https://codeload.github.com/GPUOpen-LibrariesAndSDKs/DirectXShaderCompiler/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GPUOpen-LibrariesAndSDKs%2FDirectXShaderCompiler/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265311694,"owners_count":23745106,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-07T20:34:58.357Z","updated_at":"2025-07-14T15:07:01.597Z","avatar_url":"https://github.com/GPUOpen-LibrariesAndSDKs.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# DirectX Shader Compiler\n\nThe DirectX Shader Compiler project includes a compiler and related tools used to compile High-Level Shader Language (HLSL) programs into DirectX Intermediate Language (DXIL) representation. Applications that make use of DirectX for graphics, games, and computation can use it to generate shader programs.\n\nFor more information, see the [Wiki](https://github.com/microsoft/DirectXShaderCompiler/wiki).\n\nVisit the [DirectX Landing Page](https://devblogs.microsoft.com/directx/landing-page/) for more resources for DirectX developers.\n\n## Features and Goals\n\nThe starting point of the project is a fork of the [LLVM](http://llvm.org/) and [Clang](http://clang.llvm.org/) projects, modified to accept HLSL and emit a validated container that can be consumed by GPU drivers.\n\nAt the moment, the DirectX HLSL Compiler provides the following components:\n\n- dxc.exe, a command-line tool that can compile HLSL programs for shader model 6.0 or higher\n\n- dxcompiler.dll, a DLL providing a componentized compiler, assembler, disassembler, and validator\n\n- dxilconv.dll, a DLL providing a converter from DXBC (older shader bytecode format)\n\n- various other tools based on the above components\n\nThe Microsoft Windows SDK releases include a supported version of the compiler and validator.\n\nThe goal of the project is to allow the broader community of shader developers to contribute to the language and representation of shader programs, maintaining the principles of compatibility and supportability for the platform. It's currently in active development across two axes: language evolution (with no impact to DXIL representation), and surfacing hardware capabilities (with impact to DXIL, and thus requiring coordination with GPU implementations).\n\n### Pre-built Releases\n\nDevelopment kits containing only the dxc.exe driver app, the dxcompiler.dll, and the dxil.dll signing binary are available [here](https://github.com/microsoft/DirectXShaderCompiler/wiki/Releases), or in the [releases tab](https://github.com/microsoft/DirectXShaderCompiler/releases).\n\n### SPIR-V CodeGen\n\nAs an example of community contribution, this project can also target the [SPIR-V](https://www.khronos.org/registry/spir-v/) intermediate representation. Please see the [doc](docs/SPIR-V.rst) for how HLSL features are mapped to SPIR-V, and the [wiki](https://github.com/microsoft/DirectXShaderCompiler/wiki/SPIR%E2%80%90V-CodeGen) page for how to build, use, and contribute to the SPIR-V CodeGen.\n\n## Building Sources\n\nBuilding DXC requires:\n\n* [Git](http://git-scm.com/downloads).\n* [Python](https://www.python.org/downloads/) - version 3.x is required\n* [CMake](https://cmake.org/download/) - version \u003e= 3.17.2\n    * The bundled version with Visual Studio works for Windows.\n* The C++ 14 compiler and runtime of your choosing.\n    * DXC is known to compile with recent versions of GCC, Clang and MSVC.\n\nBuilding on windows additionally requires:\n\n* [Visual Studio 2019 or later](https://www.visualstudio.com/downloads) - select the following workloads: \n    * Universal Windows Platform Development\n    * Desktop Development with C++\n* [Windows SDK](https://developer.microsoft.com/en-US/windows/downloads/windows-10-sdk) - version 10.0.18362.0 or newer\n* [Windows Driver Kit](https://docs.microsoft.com/en-us/windows-hardware/drivers/download-the-wdk) - same version as the SDK\n\n\u003e A new experimental simplified build and test workflow is documented [here](docs/BuildingAndTestingDXC.rst).\n\n\nBefore you build, you will need to have some additional software installed. This is the most straightforward path - see [Building Sources](https://github.com/microsoft/DirectXShaderCompiler/wiki/Building-Sources) on the Wiki for more options, including Visual Studio 2015 and Ninja support.\n\n* [Git](http://git-scm.com/downloads).\n* [Python](https://www.python.org/downloads/) - version 3.x is required\n* [Visual Studio 2019](https://www.visualstudio.com/downloads) - select the following workloads: \n    * Universal Windows Platform Development\n    * Desktop Development with C++\n* [Windows SDK](https://developer.microsoft.com/en-US/windows/downloads/windows-10-sdk) - version 10.0.18362.0 or newer\n* [Windows Driver Kit](https://docs.microsoft.com/en-us/windows-hardware/drivers/download-the-wdk) - same version as the SDK\n\nAfter cloning the project, you can set up a build environment shortcut by double-clicking the `utils\\hct\\hctshortcut.js` file. This will create a shortcut on your desktop with a default configuration. If your system doesn't have the requisite association for .js files, this may not work. If so, open a cmd window and invoke: `wscript.exe utils\\hct\\hctshortcut.js`.\n\nTests are built using the TAEF framework which is included in the Windows Driver Kit.\n\nTo build, run this command on the HLSL Console.\n\n    hctbuild\n\nYou can also run tests with this command.\n\n    hcttest\n\n\nTo see a list of additional commands available, run `hcthelp`\n\n## Running Tests\n\nTo run tests, open the HLSL Console and run this command after a successful build.\n\n    hcttest\n\nSome tests will run shaders and verify their behavior. These tests also involve a driver that can execute these shaders. See the next section on how this should be currently set up.\n\n## Running Shaders\n\nTo run shaders compiled as DXIL, you will need support from the operating system as well as from the driver for your graphics adapter. Windows 10 Creators Update is the first version to support DXIL shaders. See the [Wiki](https://github.com/microsoft/DirectXShaderCompiler/wiki/Running-Shaders) for information on using experimental support or the software adapter.\n\n### Hardware Support\n\nHardware GPU support for DXIL is provided by the following vendors:\n\n#### NVIDIA\nNVIDIA's r396 drivers (r397.64 and later) provide release mode support for DXIL\n1.1 and Shader Model 6.1 on Win10 1709 and later, and experimental mode support\nfor DXIL 1.2 and Shader Model 6.2 on Win10 1803 and later. These drivers also\nsupport DXR in experimental mode.\n\nDrivers can be downloaded from [geforce.com](https://www.geforce.com/drivers).\n\n#### AMD\nAMD’s driver (Radeon Software Adrenalin Edition 18.4.1 or later) provides release mode support for DXIL 1.1 and Shader Model 6.1. Drivers can be downloaded from [AMD's download site](https://support.amd.com/en-us/download).\n\n### Intel\nIntel's 15.60 drivers (15.60.0.4849 and later) support release mode for DXIL 1.0 and Shader Model 6.0 as well as\nrelease mode for DXIL 1.1 and Shader Model 6.1 (View Instancing support only).\n\nDrivers can be downloaded from the following link [Intel Graphics Drivers](https://downloadcenter.intel.com/product/80939/Graphics-Drivers)\n\nDirect access to 15.60 driver (latest as of of this update) is provided below:\n\n[Installer](https://downloadmirror.intel.com/27412/a08/win64_15.60.2.4901.exe)\n\n[Release Notes related to DXIL](https://downloadmirror.intel.com/27266/eng/ReleaseNotes_GFX_15600.4849.pdf)\n\n## Making Changes\n\nTo make contributions, see the [CONTRIBUTING.md](CONTRIBUTING.md) file in this project.\n\n## Documentation\n\nYou can find documentation for this project in the `docs` directory. These contain the original LLVM documentation files, as well as two new files worth nothing:\n\n* [HLSLChanges.rst](docs/HLSLChanges.rst): this is the starting point for how this fork diverges from the original llvm/clang sources\n* [DXIL.rst](docs/DXIL.rst): this file contains the specification for the DXIL format\n* [tools/clang/docs/UsingDxc.rst](tools/clang/docs/UsingDxc.rst): this file contains a user guide for dxc.exe\n\n## License\n\nDirectX Shader Compiler is distributed under the terms of the University of Illinois Open Source License.\n\nSee [LICENSE.txt](LICENSE.TXT) and [ThirdPartyNotices.txt](ThirdPartyNotices.txt) for details.\n\n## Code of Conduct\n\nThis project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgpuopen-librariesandsdks%2Fdirectxshadercompiler","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgpuopen-librariesandsdks%2Fdirectxshadercompiler","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgpuopen-librariesandsdks%2Fdirectxshadercompiler/lists"}