From 7ad69e2f7ee10c0e7afc302b9324e7a320424dcb Mon Sep 17 00:00:00 2001 From: Samuel Pitoiset Date: Thu, 23 Sep 2021 12:40:57 +0200 Subject: [PATCH] radv: stop loading invocation ID for NGG vertex shaders MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is unnecessary and was copied from RadeonSI which needs it for edge flags. RADV should never to read the invocation ID for VS. Signed-off-by: Samuel Pitoiset Reviewed-by: Timur Kristóf Part-of: --- src/amd/vulkan/radv_shader.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/amd/vulkan/radv_shader.c b/src/amd/vulkan/radv_shader.c index 2bddfd5a53a..bdec41c9cd9 100644 --- a/src/amd/vulkan/radv_shader.c +++ b/src/amd/vulkan/radv_shader.c @@ -1294,7 +1294,7 @@ radv_postprocess_config(const struct radv_device *device, const struct ac_shader bool tes_triangles = stage == MESA_SHADER_TESS_EVAL && info->tes.primitive_mode >= 4; /* GL_TRIANGLES */ - if (info->uses_invocation_id || stage == MESA_SHADER_VERTEX) { + if (info->uses_invocation_id) { gs_vgpr_comp_cnt = 3; /* VGPR3 contains InvocationID. */ } else if (info->uses_prim_id) { gs_vgpr_comp_cnt = 2; /* VGPR2 contains PrimitiveID. */