Mesa (11.0): r600g: write all MRTs only if there is exactly one output ( fixes a hang)
Emil Velikov
evelikov at kemper.freedesktop.org
Mon Dec 21 10:23:11 UTC 2015
Module: Mesa
Branch: 11.0
Commit: 94ac4b3e84737b8c5faa371834670fd25502e024
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=94ac4b3e84737b8c5faa371834670fd25502e024
Author: Marek Olšák <marek.olsak at amd.com>
Date: Fri Dec 18 17:16:39 2015 +0100
r600g: write all MRTs only if there is exactly one output (fixes a hang)
This fixes a hang in
piglit/arb_blend_func_extended-fbo-extended-blend-pattern_gles2 on REDWOOD.
Cc: 11.0 <mesa-stable at lists.freedesktop.org>
Reviewed-by: Alex Deucher <alexander.deucher at amd.com>
(cherry-picked from commit b5b87c4ed1dfd58aec8905e0514c9ba92ba83e1d)
Conflicts:
src/gallium/drivers/r600/r600_shader.c
---
src/gallium/drivers/r600/r600_shader.c | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/src/gallium/drivers/r600/r600_shader.c b/src/gallium/drivers/r600/r600_shader.c
index b345f14..911e81f 100644
--- a/src/gallium/drivers/r600/r600_shader.c
+++ b/src/gallium/drivers/r600/r600_shader.c
@@ -2109,7 +2109,9 @@ static int r600_shader_from_tgsi(struct r600_context *rctx,
ctx.nliterals = 0;
ctx.literals = NULL;
- shader->fs_write_all = FALSE;
+
+ shader->fs_write_all = ctx.info.properties[TGSI_PROPERTY_FS_COLOR0_WRITES_ALL_CBUFS] &&
+ ctx.info.colors_written == 1;
if (shader->vs_as_gs_a)
vs_add_primid_output(&ctx, key.vs.prim_id_out);
@@ -2140,10 +2142,6 @@ static int r600_shader_from_tgsi(struct r600_context *rctx,
case TGSI_TOKEN_TYPE_PROPERTY:
property = &ctx.parse.FullToken.FullProperty;
switch (property->Property.PropertyName) {
- case TGSI_PROPERTY_FS_COLOR0_WRITES_ALL_CBUFS:
- if (property->u[0].Data == 1)
- shader->fs_write_all = TRUE;
- break;
case TGSI_PROPERTY_VS_WINDOW_SPACE_POSITION:
if (property->u[0].Data == 1)
shader->vs_position_window_space = TRUE;
More information about the mesa-commit
mailing list