[clang][test] Use ToolSubst for spirv-tools lit substitutions#192906
Merged
Conversation
Bare-string substitutions match as substrings and the replacement path contains the tool name, causing corrupted RUN lines The issue is reproducible, for example, when path to llvm has tool name substring at any point Based on change for llvm tests: llvm#192462
Member
|
@llvm/pr-subscribers-clang Author: Arseniy Obolenskiy (aobolensk) ChangesBare-string substitutions match as substrings and the replacement path contains the tool name, causing corrupted RUN lines The issue is reproducible, for example, when path to llvm has tool name substring at any point Based on change for llvm tests: #192462 Full diff: https://github.com/llvm/llvm-project/pull/192906.diff 1 Files Affected:
diff --git a/clang/test/Tooling/lit.local.cfg b/clang/test/Tooling/lit.local.cfg
index 46d32e6ebf454..9cda4b31e81da 100644
--- a/clang/test/Tooling/lit.local.cfg
+++ b/clang/test/Tooling/lit.local.cfg
@@ -5,7 +5,7 @@ if not config.root.clang_staticanalyzer:
if config.spirv_tools_tests:
config.available_features.add("spirv-tools")
- config.substitutions.append(("spirv-dis", os.path.join(config.llvm_tools_dir, "spirv-dis")))
- config.substitutions.append(("spirv-val", os.path.join(config.llvm_tools_dir, "spirv-val")))
- config.substitutions.append(("spirv-as", os.path.join(config.llvm_tools_dir, "spirv-as")))
- config.substitutions.append(("spirv-link", os.path.join(config.llvm_tools_dir, "spirv-link")))
+ from lit.llvm import llvm_config
+ llvm_config.add_tool_substitutions(
+ ["spirv-dis", "spirv-val", "spirv-as", "spirv-link"]
+ )
|
|
LLVM Buildbot has detected a new failure on builder Full details are available at: https://lab.llvm.org/buildbot/#/builders/190/builds/40893 Here is the relevant piece of the build log for the reference |
s-perron
pushed a commit
to s-perron/llvm-project
that referenced
this pull request
Apr 21, 2026
…92906) Bare-string substitutions match as substrings and the replacement path contains the tool name, causing corrupted RUN lines The issue is reproducible, for example, when path to llvm has tool name substring at any point Based on change for llvm tests: llvm#192462
KHicketts
pushed a commit
to KHicketts/llvm-project
that referenced
this pull request
Apr 30, 2026
…92906) Bare-string substitutions match as substrings and the replacement path contains the tool name, causing corrupted RUN lines The issue is reproducible, for example, when path to llvm has tool name substring at any point Based on change for llvm tests: llvm#192462
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bare-string substitutions match as substrings and the replacement path contains the tool name, causing corrupted RUN lines
The issue is reproducible, for example, when path to llvm has tool name substring at any point
Based on change for llvm tests: #192462