From: Jerome Glisse Date: Wed, 28 Jul 2010 13:11:14 +0000 (-0400) Subject: r600g: actualy fix the literal emission X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=9961a0b92de7afed2afec62dadad08d76d1d3374;p=mesa.git r600g: actualy fix the literal emission Previous patch added literal emission to wrong place, we want to emit literal before emitting a new alu group. Signed-off-by: Jerome Glisse --- diff --git a/src/gallium/drivers/r600/r600_shader.c b/src/gallium/drivers/r600/r600_shader.c index 9796112775d..a2d641dced1 100644 --- a/src/gallium/drivers/r600/r600_shader.c +++ b/src/gallium/drivers/r600/r600_shader.c @@ -557,9 +557,6 @@ static int tgsi_slt(struct r600_shader_ctx *ctx) struct r600_bc_alu alu; int i, r; - r = r600_bc_add_literal(ctx->bc, ctx->value); - if (r) - return r; for (i = 0; i < 4; i++) { memset(&alu, 0, sizeof(struct r600_bc_alu)); if (!(inst->Dst[0].Register.WriteMask & (1 << i))) { @@ -739,6 +736,9 @@ static int tgsi_helper_copy(struct r600_shader_ctx *ctx, struct tgsi_full_instru struct r600_bc_alu alu; int i, r; + r = r600_bc_add_literal(ctx->bc, ctx->value); + if (r) + return r; for (i = 0; i < 4; i++) { memset(&alu, 0, sizeof(struct r600_bc_alu)); if (!(inst->Dst[0].Register.WriteMask & (1 << i))) {