r600g/sb: fix a bug in constants folding optimisation pass
authorXavier Bouchoux <xavierb@gmail.com>
Wed, 28 Jan 2015 01:31:58 +0000 (02:31 +0100)
committerMarek Olšák <marek.olsak@amd.com>
Fri, 6 Feb 2015 19:03:06 +0000 (20:03 +0100)
commit2fd21c4098f4574f896d7baeec6a8e5f3b7783ab
treec4b534c51c165962e5f2435f28204139c0f8c5b6
parentacef65503e79ce61a16bdba92462f0ed8a7b52c2
r600g/sb: fix a bug in constants folding optimisation pass

    ADD     R6.y.1,    R5.w.1, ~1|3f800000
    ADD     R6.y.2,    |R6.y.1|, -0.0001|b8d1b717

was wrongly being converted to

    ADD     R6.y.1,    R5.w.1, ~1|3f800000
    ADD     R6.y.2,    R5.w.1, -1.0001|bf800347

because abs() modifier was ignored.

Signed-off-by: Xavier Bouchoux <xavierb@gmail.com>
Reviewed-by: Glenn Kennard <glenn.kennard@gmail.com>
src/gallium/drivers/r600/sb/sb_expr.cpp