Skip to content

Commit

Permalink
[CI] Temporarily disable tests requiring spirv-tools in CI (#16743)
Browse files Browse the repository at this point in the history
#16724 installed `spirv-tools` on
Linux docker containers and now some llvm-spirv tests are failing due to
this (example:
https://github.com/intel/llvm/actions/runs/12915358763/job/36017038536).
In this PR, we disable detection of `spirv-tools` LIT feature
temporarily in CI to fix post-commit.

---------

Co-authored-by: Marcos Maronas <[email protected]>
  • Loading branch information
uditagarwal97 and maarquitos14 authored Jan 23, 2025
1 parent 4e5a72e commit f12546b
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 4 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/sycl-linux-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,9 @@ jobs:
cmake --build $GITHUB_WORKSPACE/build --target check-sycl-unittests
- name: check-llvm-spirv
if: always() && !cancelled() && contains(inputs.changes, 'llvm_spirv')
# Temporary workaround to disable running tests requiring spirv-tools.
env:
LIT_OPTS: "--param disable-spirv-tools=True"
run: |
cmake --build $GITHUB_WORKSPACE/build --target check-llvm-spirv
- name: check-xptifw
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/sycl-windows-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,9 @@ jobs:
cmake --build build --target check-sycl-unittests
- name: check-llvm-spirv
if: always() && !cancelled() && contains(inputs.changes, 'llvm_spirv')
# Temporary workaround to disable running tests requiring spirv-tools.
env:
LIT_OPTS: "--param disable-spirv-tools=True"
run: |
cmake --build build --target check-llvm-spirv
- name: check-xptifw
Expand Down
11 changes: 7 additions & 4 deletions llvm-spirv/test/lit.cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,24 +60,27 @@

using_spirv_tools = False

if config.spirv_tools_have_spirv_as:
# Explicitly disable using spirv tools, if requested.
disable_spirv_tools = lit_config.params.get("disable-spirv-tools", False)

if config.spirv_tools_have_spirv_as and not disable_spirv_tools:
llvm_config.add_tool_substitutions(['spirv-as'], [config.spirv_tools_bin_dir])
config.available_features.add('spirv-as')
using_spirv_tools = True

if config.spirv_tools_have_spirv_dis:
if config.spirv_tools_have_spirv_dis and not disable_spirv_tools:
llvm_config.add_tool_substitutions(['spirv-dis'], [config.spirv_tools_bin_dir])
config.available_features.add('spirv-dis')
using_spirv_tools = True

if config.spirv_tools_have_spirv_link:
if config.spirv_tools_have_spirv_link and not disable_spirv_tools:
llvm_config.add_tool_substitutions(['spirv-link'], [config.spirv_tools_bin_dir])
config.available_features.add('spirv-link')
using_spirv_tools = True

# Unlike spirv-{as,dis,link} above, running spirv-val is optional: if spirv-val is
# not available, the test must still run and just skip any spirv-val commands.
if config.spirv_tools_have_spirv_val:
if config.spirv_tools_have_spirv_val and not disable_spirv_tools:
llvm_config.add_tool_substitutions(['spirv-val'], [config.spirv_tools_bin_dir])
using_spirv_tools = True
else:
Expand Down

0 comments on commit f12546b

Please sign in to comment.