radv: call nir_link_xfb_varyings()
authorTimothy Arceri <tarceri@itsqueeze.com>
Tue, 23 Oct 2018 10:56:31 +0000 (21:56 +1100)
committerTimothy Arceri <tarceri@itsqueeze.com>
Tue, 23 Oct 2018 21:21:29 +0000 (08:21 +1100)
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
src/amd/vulkan/radv_pipeline.c

index 396b44d25a1291ed8d3a39e01f5720c2e65998b8..c21ca1743a4ae363f38d3f08e589740834d5a20c 100644 (file)
@@ -1792,6 +1792,10 @@ radv_link_shaders(struct radv_pipeline *pipeline, nir_shader **shaders)
                unsigned first = ordered_shaders[shader_count - 1]->info.stage;
                unsigned last = ordered_shaders[0]->info.stage;
 
+               if (ordered_shaders[0]->info.stage == MESA_SHADER_FRAGMENT &&
+                   ordered_shaders[1]->info.has_transform_feedback_varyings)
+                       nir_link_xfb_varyings(ordered_shaders[1], ordered_shaders[0]);
+
                for (int i = 0; i < shader_count; ++i)  {
                        nir_variable_mode mask = 0;