[Mesa-dev] [PATCH v2 10/13] i965: Make TES inputs match TCS outputs.
Jordan Justen
jordan.l.justen at intel.com
Sun Dec 13 00:03:35 PST 2015
Reviewed-by: Jordan Justen <jordan.l.justen at intel.com>
On 2015-12-11 13:23:59, Kenneth Graunke wrote:
> Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>
> ---
> src/mesa/drivers/dri/i965/brw_nir.c | 11 +++++++++++
> 1 file changed, 11 insertions(+)
>
> diff --git a/src/mesa/drivers/dri/i965/brw_nir.c b/src/mesa/drivers/dri/i965/brw_nir.c
> index d405991..3cb6123 100644
> --- a/src/mesa/drivers/dri/i965/brw_nir.c
> +++ b/src/mesa/drivers/dri/i965/brw_nir.c
> @@ -641,6 +641,17 @@ brw_create_nir(struct brw_context *brw,
> /* First, lower the GLSL IR or Mesa IR to NIR */
> if (shader_prog) {
> nir = glsl_to_nir(shader_prog, stage, options);
> +
> + if (nir->stage == MESA_SHADER_TESS_EVAL &&
> + shader_prog->_LinkedShaders[MESA_SHADER_TESS_CTRL]) {
> + const struct gl_program *tcs =
> + shader_prog->_LinkedShaders[MESA_SHADER_TESS_CTRL]->Program;
> + /* Work around the TCS having bonus outputs used as shared memory
> + * segments, which makes OutputsWritten not match InputsRead
> + */
> + nir->info.inputs_read = tcs->OutputsWritten;
> + nir->info.patch_inputs_read = tcs->PatchOutputsWritten;
> + }
> } else {
> nir = prog_to_nir(prog, options);
> OPT_V(nir_convert_to_ssa); /* turn registers into SSA */
> --
> 2.6.3
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev
More information about the mesa-dev
mailing list