diff --git a/src/amd/vulkan/nir/radv_nir.h b/src/amd/vulkan/nir/radv_nir.h index 082cfbbd622..98f412da14a 100644 --- a/src/amd/vulkan/nir/radv_nir.h +++ b/src/amd/vulkan/nir/radv_nir.h @@ -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); diff --git a/src/amd/vulkan/nir/radv_nir_lower_io.c b/src/amd/vulkan/nir/radv_nir_lower_io.c index 3243c9b2a88..a5b80bc4e2d 100644 --- a/src/amd/vulkan/nir/radv_nir_lower_io.c +++ b/src/amd/vulkan/nir/radv_nir_lower_io.c @@ -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); diff --git a/src/amd/vulkan/radv_pipeline_graphics.c b/src/amd/vulkan/radv_pipeline_graphics.c index 3dfda1f67a7..bb7716239dc 100644 --- a/src/amd/vulkan/radv_pipeline_graphics.c +++ b/src/amd/vulkan/radv_pipeline_graphics.c @@ -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. */