freedreno/ir3: allow layer/viewport output for VS/GS/DS

With VK_EXT_shader_viewport_index_layer, these stages can all output the
viewport or layer id, and not just GS anymore.

Signed-off-by: Jonathan Marek <jonathan@marek.ca>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5832>
This commit is contained in:
Jonathan Marek
2020-07-09 14:22:12 -04:00
committed by Marge Bot
parent 338745c6f4
commit e732750b16

View File

@@ -3140,7 +3140,6 @@ setup_output(struct ir3_context *ctx, nir_intrinsic_instr *intr)
so->writes_psize = true;
break;
case VARYING_SLOT_PRIMITIVE_ID:
case VARYING_SLOT_LAYER:
case VARYING_SLOT_GS_VERTEX_FLAGS_IR3:
debug_assert(ctx->so->type == MESA_SHADER_GEOMETRY);
/* fall through */
@@ -3152,6 +3151,8 @@ setup_output(struct ir3_context *ctx, nir_intrinsic_instr *intr)
case VARYING_SLOT_CLIP_DIST0:
case VARYING_SLOT_CLIP_DIST1:
case VARYING_SLOT_CLIP_VERTEX:
case VARYING_SLOT_LAYER:
case VARYING_SLOT_VIEWPORT:
break;
default:
if (slot >= VARYING_SLOT_VAR0)