radv: never call nir_assign_io_var_locations

The comment is outdated and this info is never used.

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40982>
This commit is contained in:
Georg Lehmann 2026-04-15 14:14:21 +02:00 committed by Marge Bot
parent 97c7e4b41f
commit f85767a035
3 changed files with 4 additions and 14 deletions

View file

@ -61,7 +61,7 @@ bool radv_nir_export_multiview(nir_shader *nir);
unsigned radv_map_io_driver_location(unsigned semantic);
void radv_nir_lower_io(struct radv_device *device, nir_shader *nir);
void radv_nir_lower_io(nir_shader *nir);
bool radv_nir_lower_io_to_mem(struct radv_device *device, struct radv_shader_stage *stage);

View file

@ -22,10 +22,8 @@ type_size_vec4(const struct glsl_type *type, bool bindless)
}
void
radv_nir_lower_io(struct radv_device *device, nir_shader *nir)
radv_nir_lower_io(nir_shader *nir)
{
const struct radv_physical_device *pdev = radv_device_physical(device);
/* The nir_lower_io pass currently cannot handle array deref of vectors.
* Call this here to make sure there are no such derefs left in the shader.
*/
@ -43,17 +41,9 @@ radv_nir_lower_io(struct radv_device *device, nir_shader *nir)
/* Fold constant offset srcs for IO. */
NIR_PASS(_, nir, nir_opt_constant_folding);
if (nir->xfb_info) {
if (nir->xfb_info)
NIR_PASS(_, nir, nir_io_add_intrinsic_xfb_info);
if (pdev->use_ngg_streamout) {
/* The total number of shader outputs is required for computing the pervertex LDS size for
* VS/TES when lowering NGG streamout.
*/
nir_assign_io_var_locations(nir, nir_var_shader_out);
}
}
if (nir->info.stage == MESA_SHADER_FRAGMENT) {
/* Lower explicit input load intrinsics to sysvals for the layer ID. */
NIR_PASS(_, nir, nir_lower_system_values);

View file

@ -2635,7 +2635,7 @@ radv_graphics_shaders_compile(struct radv_device *device, struct vk_pipeline_cac
}
}
radv_nir_lower_io(device, stages[i].nir);
radv_nir_lower_io(stages[i].nir);
if (!stages[i].key.optimisations_disabled) {
/* Scalarize all I/O, because nir_opt_varyings and nir_opt_vectorize_io expect all I/O to be scalarized. */