r600g: reorder LIT instructions to support src == dst
authorPierre-Eric Pelloux-Prayer <pelloux@gmail.com>
Mon, 20 Jun 2011 09:42:23 +0000 (11:42 +0200)
committerDave Airlie <airlied@redhat.com>
Tue, 21 Jun 2011 02:50:44 +0000 (12:50 +1000)
commitabe74a9820bc5b512ab24518622368db20187637
treed1472c3e187ab98283e82020ecc02e2c337fcacd
parent4112ca54e3769ca2ceeb4d82a4e2bc3dc52cc134
r600g: reorder LIT instructions to support src == dst

the attached patch should be an improvement over Vadim Girlin's patch
fixing LIT instruction for r600g (commit
2fe39b46e73aea37152777fe11d489e0b1bc3f92).

Instructions used in tgsi_lit have been reordered to always write to a
dst channel after the same channel in src has been read (so if src ==
dst, input values are not overwritten before being used).

Signed-off-by: Dave Airlie <airlied@redhat.com>
src/gallium/drivers/r600/r600_shader.c