[clang] Add spirv-val compilation step when targeting SPIR-V (PR #188150)
Joshua Batista via cfe-commits
cfe-commits at lists.llvm.org
Fri Apr 3 16:09:36 PDT 2026
================
@@ -5431,11 +5393,9 @@ void Driver::BuildJobs(Compilation &C) const {
unsigned NumOutputs = 0;
unsigned NumIfsOutputs = 0;
for (const Action *A : C.getActions()) {
- // The actions below do not increase the number of outputs, when operating
- // on DX containers.
- if (A->getType() == types::TY_DX_CONTAINER &&
- (A->getKind() == clang::driver::Action::BinaryAnalyzeJobClass ||
- A->getKind() == clang::driver::Action::BinaryTranslatorJobClass))
+ // The actions below do not increase the number of outputs.
+ if (A->getKind() == clang::driver::Action::BinaryAnalyzeJobClass ||
+ A->getKind() == clang::driver::Action::BinaryTranslatorJobClass)
----------------
bob80905 wrote:
Yes, the old TY_DX_CONTAINER check was just being overly careful. At the time it was written, DXIL was the only target that used BinaryAnalyzeJobClass or BinaryTranslatorJobClass, so the type check was redundant but harmless. Removing the type check makes this work for SPIR-V (which uses TY_Object) without changing any existing DXIL behavior.
https://github.com/llvm/llvm-project/pull/188150
More information about the cfe-commits
mailing list