Since v1.12.0, kernels compiled for SPIRVCompilerTarget (OpenCL.jl + pocl_jll) (KA on CPU) can produce SPIR-V that spirv-val rejects with:
error: line 0: The following forward referenced IDs have not been defined:
'308[%308]'
git bisect between v1.11.1 (good) and v1.13.2 (bad) identifies commit c095147 ("Align optimization pipeline with Julia's") as the first bad commit. A sub-bisection within c095147 narrows the cause to a single newly-added pass in buildScalarOptimizerPipeline:
# src/optim.jl, in the opt_level >= 2 branch
add!(fpm, VectorCombinePass())
Maybe guarding it like this is fine?
if can_vectorize(job)
add!(fpm, VectorCombinePass())
end
Since v1.12.0, kernels compiled for
SPIRVCompilerTarget(OpenCL.jl +pocl_jll) (KA on CPU) can produce SPIR-V thatspirv-valrejects with:git bisectbetween v1.11.1 (good) and v1.13.2 (bad) identifies commitc095147("Align optimization pipeline with Julia's") as the first bad commit. A sub-bisection withinc095147narrows the cause to a single newly-added pass inbuildScalarOptimizerPipeline:Maybe guarding it like this is fine?