mesa/compiler: copy early fragment tests to shader_info in _mesa_copy_linked_program_...
authorTimothy Arceri <timothy.arceri@collabora.com>
Thu, 20 Oct 2016 03:09:15 +0000 (14:09 +1100)
committerTimothy Arceri <timothy.arceri@collabora.com>
Wed, 26 Oct 2016 03:29:36 +0000 (14:29 +1100)
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
src/compiler/shader_info.c
src/mesa/main/shaderapi.c

index 49361bcbdf98c582d1ff76e9b251509ae0481556..34aaf9f21fd97c96babecf8b547c164d95e7cade 100644 (file)
@@ -38,8 +38,4 @@ copy_shader_info(const struct gl_shader_program *shader_prog,
    info->patch_outputs_written = sh->Program->PatchOutputsWritten;
    info->system_values_read = sh->Program->SystemValuesRead;
    info->uses_texture_gather = sh->Program->UsesGather;
-
-   if (sh->Stage == MESA_SHADER_FRAGMENT) {
-      sh->Program->info.fs.early_fragment_tests = sh->info.EarlyFragmentTests;
-   }
 }
index 4996e8ed1d792a5fb91bfe5f4d2d4f816a82d9e8..73b8931bda6728c269b8b75fdaa92b68eac37a1e 100644 (file)
@@ -2197,6 +2197,7 @@ _mesa_copy_linked_program_data(const struct gl_shader_program *src,
    }
    case MESA_SHADER_FRAGMENT: {
       dst->info.fs.depth_layout = src->FragDepthLayout;
+      dst->info.fs.early_fragment_tests = dst_sh->info.EarlyFragmentTests;
       break;
    }
    case MESA_SHADER_COMPUTE: {