From: Nicolai Hähnle Date: Fri, 18 Nov 2016 19:51:56 +0000 (+0100) Subject: st/mesa: skip lower_output_reads when possible X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=f60374aa689539c8dbdb851488be515e5e7df7cb;p=mesa.git st/mesa: skip lower_output_reads when possible Reviewed-by: Marek Olšák --- diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp index 8a247ea68d7..7720edfb528 100644 --- a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp +++ b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp @@ -6445,7 +6445,8 @@ get_mesa_program_tgsi(struct gl_context *ctx, prog->Parameters); /* Remove reads from output registers. */ - lower_output_reads(shader->Stage, shader->ir); + if (!pscreen->get_param(pscreen, PIPE_CAP_TGSI_CAN_READ_OUTPUTS)) + lower_output_reads(shader->Stage, shader->ir); /* Emit intermediate IR for main(). */ visit_exec_list(shader->ir, v);