From: Jordan Justen Date: Tue, 15 Dec 2015 02:12:57 +0000 (-0800) Subject: nir/spirv_to_nir: Use a minimum of 1 for GS invocations X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=a3c5c339a8dcda213f8e3f6a56b44080b4c4eda7;p=mesa.git nir/spirv_to_nir: Use a minimum of 1 for GS invocations glslang is giving us 0, which causes the SIMD8 GS compile to hit an assert. Signed-off-by: Jordan Justen --- diff --git a/src/glsl/nir/spirv_to_nir.c b/src/glsl/nir/spirv_to_nir.c index e101e1edcb0..a8f3016e050 100644 --- a/src/glsl/nir/spirv_to_nir.c +++ b/src/glsl/nir/spirv_to_nir.c @@ -3075,7 +3075,7 @@ vtn_handle_preamble_instruction(struct vtn_builder *b, SpvOp opcode, case SpvExecutionModeInvocations: assert(b->shader->stage == MESA_SHADER_GEOMETRY); - b->shader->info.gs.invocations = w[3]; + b->shader->info.gs.invocations = MAX2(1, w[3]); break; case SpvExecutionModeDepthReplacing: