From 4bb2e42fb4e642d9761567f3eaf6639708408907 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timur=20Krist=C3=B3f?= Date: Fri, 7 May 2021 13:09:19 +0200 Subject: [PATCH] radv: Properly enable Wave32 mode for NGG GS. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The condition for enabling it was incorrect, and was always false. Therefore, it was never really enabled. Signed-off-by: Timur Kristóf Reviewed-by: Samuel Pitoiset Part-of: --- src/amd/vulkan/radv_pipeline.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/amd/vulkan/radv_pipeline.c b/src/amd/vulkan/radv_pipeline.c index 5a07d652a0e..14b2e4ad202 100644 --- a/src/amd/vulkan/radv_pipeline.c +++ b/src/amd/vulkan/radv_pipeline.c @@ -2805,9 +2805,10 @@ radv_fill_shader_keys(struct radv_device *device, struct radv_shader_variant_key static uint8_t radv_get_wave_size(struct radv_device *device, const VkPipelineShaderStageCreateInfo *pStage, - gl_shader_stage stage, const struct radv_shader_variant_key *key) + gl_shader_stage stage, const struct radv_shader_variant_key *key, + const struct radv_shader_info *info) { - if (stage == MESA_SHADER_GEOMETRY && !key->vs_common_out.as_ngg) + if (stage == MESA_SHADER_GEOMETRY && !info->is_ngg) return 64; else if (stage == MESA_SHADER_COMPUTE) { return key->cs.subgroup_size; @@ -2918,7 +2919,7 @@ radv_fill_shader_info(struct radv_pipeline *pipeline, for (int i = 0; i < MESA_SHADER_STAGES; i++) { if (nir[i]) { - infos[i].wave_size = radv_get_wave_size(pipeline->device, pStages[i], i, &keys[i]); + infos[i].wave_size = radv_get_wave_size(pipeline->device, pStages[i], i, &keys[i], &infos[i]); infos[i].ballot_bit_size = radv_get_ballot_bit_size(pipeline->device, pStages[i], i, &keys[i]); }