i965: get outputs_written from gl_program
authorTimothy Arceri <timothy.arceri@collabora.com>
Fri, 18 Nov 2016 05:46:27 +0000 (16:46 +1100)
committerTimothy Arceri <timothy.arceri@collabora.com>
Thu, 19 Jan 2017 06:05:26 +0000 (17:05 +1100)
There is no need to go via the pointer in nir_shader. This change
is required for the shader cache as we don't create a nir_shader.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
src/mesa/drivers/dri/i965/brw_vs.c

index 5d1993931819838fbd3e758a55ac0013ddc59861..3bcd7c67ee6e313c595a032943d66784ec2662f9 100644 (file)
@@ -310,7 +310,7 @@ brw_vs_populate_key(struct brw_context *brw,
       }
    }
 
-   if (prog->nir->info->outputs_written &
+   if (prog->info.outputs_written &
        (VARYING_BIT_COL0 | VARYING_BIT_COL1 | VARYING_BIT_BFC0 |
         VARYING_BIT_BFC1)) {
       /* _NEW_LIGHT | _NEW_BUFFERS */
@@ -364,7 +364,7 @@ brw_vs_precompile(struct gl_context *ctx, struct gl_program *prog)
    brw_setup_tex_for_precompile(brw, &key.tex, prog);
    key.program_string_id = bvp->id;
    key.clamp_vertex_color =
-      (prog->nir->info->outputs_written &
+      (prog->info.outputs_written &
        (VARYING_BIT_COL0 | VARYING_BIT_COL1 | VARYING_BIT_BFC0 |
         VARYING_BIT_BFC1));