nir: Initialize workgroup_size in builder_init_simple_shader
It can't be 0 in Vulkan. Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24158>
This commit is contained in:
committed by
Marge Bot
parent
ce25668d02
commit
d0f0afc6a4
@@ -50,6 +50,13 @@ nir_builder_init_simple_shader(gl_shader_stage stage,
|
||||
/* Simple shaders are typically internal, e.g. blit shaders */
|
||||
b.shader->info.internal = true;
|
||||
|
||||
/* Compute shaders on Vulkan require some workgroup size initialized, pick
|
||||
* a safe default value. This relies on merging workgroups for efficiency.
|
||||
*/
|
||||
b.shader->info.workgroup_size[0] = 1;
|
||||
b.shader->info.workgroup_size[1] = 1;
|
||||
b.shader->info.workgroup_size[2] = 1;
|
||||
|
||||
return b;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user