From 6f88b07e5d3c5601bf5941c495dd4a57478081f4 Mon Sep 17 00:00:00 2001 From: Natalie Vock Date: Wed, 18 Feb 2026 18:22:21 +0100 Subject: [PATCH] radv: Initialize nir_lower_io_to_scalar progress variable The NIR_PASS macro only overwrites this when the pass actually makes progress. If the pass doesn't make progress, the variable stays uninitialized. Clang correctly spots this and warns about it. Cc: mesa-stable (cherry picked from commit 47e4a68a838347e65a5d4bef421d7c44c6f98314) Part-of: --- .pick_status.json | 2 +- src/amd/vulkan/radv_pipeline_graphics.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.pick_status.json b/.pick_status.json index 735d9853da9..78f2a1223de 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -2804,7 +2804,7 @@ "description": "radv: Initialize nir_lower_io_to_scalar progress variable", "nominated": true, "nomination_type": 1, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": null, "notes": null diff --git a/src/amd/vulkan/radv_pipeline_graphics.c b/src/amd/vulkan/radv_pipeline_graphics.c index d56b10c2daa..5dc6b3c7212 100644 --- a/src/amd/vulkan/radv_pipeline_graphics.c +++ b/src/amd/vulkan/radv_pipeline_graphics.c @@ -1662,7 +1662,7 @@ radv_graphics_shaders_link_varyings(struct radv_shader_stage *stages, enum amd_g /* Scalarize all I/O, because nir_opt_varyings and nir_opt_vectorize_io expect all I/O to be scalarized. */ nir_variable_mode sca_mode = nir_var_shader_in; - bool sca_progress; + bool sca_progress = false; if (s != MESA_SHADER_FRAGMENT) sca_mode |= nir_var_shader_out;