Update SPIR-V Headers to 5e3ad389e

Changes:
    5e3ad389e VkspReflection non-sematic: add dispatchId in configuration (#425)
    4f7b471f1 Update bit reservations for loop controsl and memory operands (#424)
    7d500c4d7 Register LLVM SPIR-V Backend as SPIR-V generator (#423)
    04db24d69 Register spq tools for SPIR-V (#399)
    8b246ff75 Add SPV_NV_raw_access_chains (#417)
    b73e168ca Headers support for SPV_INTEL_maximum_registers extension (#416)
    05cc48658 Add SPV_NV_shader_atomic_fp16_vector (#420)
    69597bee0 SPV_QCOM_image_processing2 (#419)
    3b11b0209 cmake: Allow external control of test and install options (#418)
    d3c2a6fa9 remove Kernel from Image Channel Order and Channel Data Type enums (#413)
    e77d03080 Update FPFastMath token reservation (#414)
    1c9115b56 List all licenses in the root LICENSE file. (#410)
    5aa1dd8a1 Support SPV_KHR_quad_control (with fixed line endings) (#412)
    ae6a8b397 SPV_KHR_float_controls2 (#409)
    2b9ba211f Add SPV_KHR_maximal_reconvergence (#407)
    23d4a398c update copyright dates to 2024 (#404)
    7b0309708 Register Zig Compiler tool (#405)
    eb36f6c60 Add a Source Language for Zig (#403)
    bdd1b2ab1 Reserve an FPFastMathMode bit (#401)
    c4a13e774 Bump the github-actions group with 1 update (#400)
    2e3dc2e17 Publish the header for the vulkan-shader-profiler embedded reflection… (#398)
    1bfd27101 Upstream tokens for SPV_INTEL_masked_gather_scatter (#391)
    e11db4d69 feat: Create dependabot.yml (#397)
    1c6bb2743 Add a few missing calls to std::exit on error (#395)
    d5301a8d3 Headers support for FPGAClusterAttributesV2INTEL (#393)
    f1e0d8b51 Add Type-Declaration for extended types (#392)
    d5acd42cb Update SPV_INTEL_long_composites tokens (#375)
    cca08c63c Change token IDs for global_variable_fpga_decorations and global_variable_host_access (#389)
    be3c81e3f It seems d790ced752b5bfc06b6988baadef6eb2d16bdf96 add tabs. (#390)
    38f39dae5 Fix SPV_KHR_workgroup_memory_explicit_layout implicit declare (#388)
    88bc5e321 Headers support for new FPGAMemoryAttributesINTEL (#384)
    4183b260f ClspvReflection non-sematic: add NormalizedSamplerMaskPushConstant (#377)
    e867c0663 Add a Source Language for Slang (#383)
    f62c82d6b Register Slang Compiler for SPIR-V (#382)
    79743b899 Add LiteralFloat to operand_kinds (#380)
    f8a4f5d87 Add headers for SPV_NV_displacement_micromap. (#374)
    d741b924e remove additional version "1.0" from SecondaryViewportRelativeNV (#379)
    fc7d24627 Remove Kernel from ConstantSampler enum values (#378)
    a8af2ce34 Add SPV_INTEL_cache_controls extension support (#376)
    d790ced75 Validate enums have sensible versions and are visible (#369)
    b8b9eb864 Headers support for two Intel extensions (#356)
    45fc02a6c Merge pull request #366 from KonstantinSeurer/main
    b730938c0 Merge pull request #371 from dneto0/cooperative-matrix-enums-fewer-deps
    c43effd54 Revert "Merge pull request #367 from dneto0/coop-matrix-enums-deps"
    124a9665e Merge pull request #367 from dneto0/coop-matrix-enums-deps
    b846bb75c Cooperative matrix enums depend on the extension
    c6e625d2c Add SPV_AMDX_shader_enqueue
    f14a663c8 Merge pull request #361 from kpet/coop-matrix-capabilities-alignment
    ae89923fa Merge pull request #364 from kpet/coopmatrix-khr-suffix
    272be321a Add KHR suffix to Cooperative Matrix Operands
    51b106461 Recommit PR #348 - Add fp-max-error support (#363)
    14914db17 Merge pull request #360 from kpet/make-headers-error-reporting
    0e7d41e27 Report failures in makeHeaders
    66e500034 Merge pull request #362 from KhronosGroup/revert-348-asudarsa/add_fp_max_error_support
    5c9c56177 Revert "Add support for fp_max_error extension"
    ac3b50f84 Remove capabilities on cooperative matrix enums to align with specification
    88d56db61 Merge pull request #348 from asudarsa/asudarsa/add_fp_max_error_support
    f1ba373ef Merge pull request #358 from alan-baker/wgsl-source-language
    5928a8dc7 Merge pull request #353 from joycebrum/main
    7d8a844df Add WGSL source language
    d0006a393 Merge pull request #357 from SirLynix/patch-1
    fb116d7ba Regenerate headers
    d90fd3429 Add NZSL as a source language
    abca639b3 Add NZSLc as a generator
    3469b164e Merge pull request #355 from kpet/spv-khr-cooperative-matrix
    6b5af05fb fix operand names
    3ca8d522a Change kind of FPMaxErrorDecorationINTEL to LiteralFloat
    9b527c0fb Add definitions for SPV_KHR_cooperative_matrix
    10db9d4e1 Merge pull request #354 from kpet/spv-ext-image-raw10-raw12
    72e4c7e8c Add definitions for SVP_EXT_image_raw10_raw12
    0d21d5612 Create SECURITY.md
    6e09e44cd Merge pull request #350 from facebook/meta_enums
    eb2506428 Reserve SPIR-V enums for Meta
    33ec2e8a5 Interchange capability and decoration
    866d16777 Merge remote-tracking branch 'real-origin/main' into asudarsa/add_fp_max_error_support
    8e2ad2748 Merge pull request #338 from heroseh/main
    f48f8eed1 Merge branch 'main' of https://github.com/KhronosGroup/SPIRV-Headers
    730800f6d regenerate headers & correct order of TileImage*ReadAccessEXT Capability enum
    30e0e73ab add HERO_C to the source language enumeration
    69155b22b Merge pull request #347 from jjfumero/update-spirv-tool
    ae96002ae Name and url for the TornadoVM SPIR-V Library Tool updated
    bdbfd019b Merge pull request #346 from kpet/constexpr-maskall
    d8c780f48 Make the generated operators for masks constexpr
    fc2395fd2 Add Hero C Compiler to the vendor list & add C source language to the Source Language enum
    9bebe8674 Add parameters
    d9d7078e3 Merge remote-tracking branch 'real-origin/main' into asudarsa/add_fp_max_error_support
    f46e295b2 Header files changes to support SPV_INTEL_fp_max_error spec extension

Commands:
    ./third_party/update-spirvheaders.sh

Bug: b/123642959
Change-Id: I0e5a3672ba44bb5aeeee333d24febd05f7247190
Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/73371
Tested-by: Ben Clayton <bclayton@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Presubmit-Ready: Romaric Jodin <rjodin@chromium.org>
Tested-by: Romaric Jodin <rjodin@chromium.org>
Reviewed-by: Ben Clayton <bclayton@google.com>
tree: 8eb411285e32c961a99fbfe052c61d609dd5cf8e
  1. .vscode/
  2. build/
  3. build_overrides/
  4. docs/
  5. include/
  6. infra/
  7. src/
  8. tests/
  9. third_party/
  10. tools/
  11. .clang-format
  12. .dir-locals.el
  13. .gitignore
  14. .gitmodules
  15. Android.bp
  16. AUTHORS.txt
  17. BUILD.gn
  18. CMakeLists.txt
  19. CMakeSettings.json
  20. codereview.settings
  21. CONTRIBUTING.txt
  22. CONTRIBUTORS.txt
  23. DIR_METADATA
  24. LICENSE.txt
  25. OWNERS
  26. README.md
README.md

SwiftShader

License

Introduction

SwiftShader[^1] is a high-performance CPU-based implementation[^2] of the Vulkan[^3] 1.3 graphics API. Its goal is to provide hardware independence for advanced 3D graphics.

NOTE: The ANGLE project can be used to achieve a layered implementation[^4] of OpenGL ES 3.1 (aka. “SwANGLE”).

Building

SwiftShader libraries can be built for Windows, Linux, and macOS.
Android and Chrome (OS) build environments are also supported.

  • CMake
    Install CMake for Linux, macOS, or Windows and use either the GUI or run the following terminal commands:

    cd build
    cmake ..
    cmake --build . --parallel
    
    ./vk-unittests
    

    Tip: Set the CMAKE_BUILD_PARALLEL_LEVEL environment variable to control the level of parallelism.

  • Visual Studio
    To build the Vulkan ICD library, use Visual Studio 2019 to open the project folder and wait for it to run CMake. Open the CMake Targets View in the Solution Explorer and select the vk_swiftshader project to build it.

Usage

The SwiftShader libraries act as drop-in replacements for graphics drivers.

On Windows, most applications can be made to use SwiftShader's DLLs by placing them in the same folder as the executable. On Linux, the LD_LIBRARY_PATH environment variable or -rpath linker option can be used to direct applications to search for shared libraries in the indicated directory first.

In general, Vulkan applications look for a shared library named vulkan-1.dll on Windows (vulkan-1.so on Linux). This ‘loader’ library then redirects API calls to the actual Installable Client Driver (ICD). SwiftShader's ICD is named libvk_swiftshader.dll, but it can be renamed to vulkan-1.dll to be loaded directly by the application. Alternatively, you can set the VK_ICD_FILENAMES environment variable to the path to vk_swiftshader_icd.json file that is generated under the build directory (e.g. .\SwiftShader\build\Windows\vk_swiftshader_icd.json). To learn more about how Vulkan loading works, read the official documentation here.

Contributing

See CONTRIBUTING.txt for important contributing requirements.

The canonical repository for SwiftShader is hosted at: https://swiftshader.googlesource.com/SwiftShader.

All changes must be reviewed and approved in the Gerrit review tool at: https://swiftshader-review.googlesource.com. You must sign in to this site with a Google Account before changes can be uploaded.

Next, authenticate your account here: https://swiftshader.googlesource.com/new-password (use the same e-mail address as the one configured as the Git commit author).

All changes require a Change-ID tag in the commit message. A commit hook may be used to add this tag automatically, and can be found at: https://gerrit-review.googlesource.com/tools/hooks/commit-msg. You can execute git clone https://swiftshader.googlesource.com/SwiftShader and manually place the commit hook in SwiftShader/.git/hooks/, or to clone the repository and install the commit hook in one go:

git clone https://swiftshader.googlesource.com/SwiftShader && (cd SwiftShader && git submodule update --init --recursive third_party/git-hooks && ./third_party/git-hooks/install_hooks.sh)

On Windows, this command line requires using the Git Bash Shell.

Changes are uploaded to Gerrit by executing:

git push origin HEAD:refs/for/master

When ready, add a project owner as a reviewer on your change.

Some tests will automatically be run against the change. Notably, presubmit.sh verifies the change has been formatted using clang-format 11.0.1. Most IDEs come with clang-format support, but may require upgrading/downgrading to the clang-format version 11.0.0 release version (notably Chromium's buildtools has a clang-format binary which can be an in-between revision which produces different formatting results).

Testing

SwiftShader's Vulkan implementation can be tested using the dEQP test suite.

See docs/dEQP.md for details.

Third-Party Dependencies

The third_party directory contains projects which originated outside of SwiftShader:

subzero contains a fork of the Subzero project. It originates from Google Chrome‘s (Portable) Native Client project. The fork was made using git-subtree to include all of Subzero’s history.

llvm-subzero contains a minimized set of LLVM dependencies of the Subzero project.

PowerVR_SDK contains a subset of the PowerVR Graphics Native SDK for running several sample applications.

googletest contains the Google Test project, as a Git submodule. It is used for running unit tests for Chromium, and Reactor unit tests. Run git submodule update --init to obtain/update the code. Any contributions should be made upstream.

Documentation

See docs/Index.md.

Contact

Public mailing list: swiftshader@googlegroups.com

General bug tracker: https://g.co/swiftshaderbugs
Chrome specific bugs: https://bugs.chromium.org/p/swiftshader

License

The SwiftShader project is licensed under the Apache License Version 2.0. You can find a copy of it in LICENSE.txt.

Files in the third_party folder are subject to their respective license.

Authors and Contributors

The legal authors for copyright purposes are listed in AUTHORS.txt.

CONTRIBUTORS.txt contains a list of names of individuals who have contributed to SwiftShader. If you‘re not on the list, but you’ve signed the Google CLA and have contributed more than a formatting change, feel free to request to be added.

Notes and Disclaimers

[^1]: This is not an official Google product.
[^2]: Vulkan 1.3 conformance: https://www.khronos.org/conformance/adopters/conformant-products#submission_717
[^3]: Trademarks are the property of their respective owners.
[^4]: OpenGL ES 3.1 conformance: https://www.khronos.org/conformance/adopters/conformant-products/opengles#submission_906