diff options
author | Natalie Chouinard <sudonatalie@google.com> | 2023-12-04 12:24:51 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-12-04 12:24:51 -0500 |
commit | f368e6424fbfb7fdea4b9d9a2e44f2f7e188c133 (patch) | |
tree | 3bed7a3511702e2a6ad3c5958c726681eb012b14 /clang/lib/Frontend/CompilerInvocation.cpp | |
parent | dff2f59be39765c8d6814c9a06155f76a5393673 (diff) | |
download | llvm-f368e6424fbfb7fdea4b9d9a2e44f2f7e188c133.zip llvm-f368e6424fbfb7fdea4b9d9a2e44f2f7e188c133.tar.gz llvm-f368e6424fbfb7fdea4b9d9a2e44f2f7e188c133.tar.bz2 |
[SPIR-V] Add SPIRV-Tools for testing (#73044)
Add spirv-dis (disassembler) and spirv-val (validator) from SPIRV-Tools
as external dependencies for testing the SPIR-V backend. These tools are
test dependencies only.
SPIR-V backend tests now have a dependency on the spirv-dis and
spirv-val targets when the `LLVM_INCLUDE_SPIRV_TOOLS_TESTS` cmake
variable is set, which allows additional test files with the `REQUIRES:
spirv-tools` constraint to run, along with additional `RUN: %if
spirv-tools ...` lines in existing tests. All other SPIR-V backend tests
will run normally when `LLVM_INCLUDE_SPIRV_TOOLS_TESTS` is not set.
Several tests are included to show these tools' use, however more tests
will be migrated and added later.
* OpVariable_order.ll shows how spirv-val can catch bugs in the backend.
* basic_int_types_spirvdis.ll shows how tests can be much shorter and
more readable by FileChecking the spirv-dis output.
* basic_int_types.ll shows how an additional RUN line can add validation
to existing tests.
RFC:
https://discourse.llvm.org/t/rfc-add-a-test-dependency-on-spirv-tools/75135
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions