mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 09:28:07 +02:00
clover: Call clang with -O0 for the SPIR-V path
SPIRV-LLVM-Translator isn't really built for handling optimized LLVM IR. It tends to fall over when, for instance, an optimization generates an i96 type which isn't legal in SPIR-V. Pass -O0 to avoid these cases. See https://github.com/KhronosGroup/SPIRV-LLVM-Translator/issues/203. Reviewed-by: Karol Herbst <kherbst@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6432>
This commit is contained in:
parent
e3e45e2456
commit
32dc71b23a
1 changed files with 1 additions and 1 deletions
|
|
@ -450,7 +450,7 @@ clover::llvm::compile_to_spirv(const std::string &source,
|
|||
"-spir-unknown-unknown" :
|
||||
"-spir64-unknown-unknown";
|
||||
auto c = create_compiler_instance(dev, target,
|
||||
tokenize(opts + " input.cl"), r_log);
|
||||
tokenize(opts + " -O0 input.cl"), r_log);
|
||||
auto mod = compile(*ctx, *c, "input.cl", source, headers, dev, opts, false,
|
||||
r_log);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue