summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i965/brw_sf_emit.c
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2012-08-06 14:59:39 -0700
committerEric Anholt <eric@anholt.net>2012-08-08 16:21:30 -0700
commit9b4053cabd8bda180b352d2d2047209f6ca5f6e8 (patch)
tree98e1bc1e07fa9ba203fb52e8cafa5ba0ff3d80a2 /src/mesa/drivers/dri/i965/brw_sf_emit.c
parent33dfdc735e052d9c9b33883350e926d40220b6ac (diff)
downloadexternal_mesa3d-9b4053cabd8bda180b352d2d2047209f6ca5f6e8.zip
external_mesa3d-9b4053cabd8bda180b352d2d2047209f6ca5f6e8.tar.gz
external_mesa3d-9b4053cabd8bda180b352d2d2047209f6ca5f6e8.tar.bz2
i965: Drop the confusing saturate argument to math instruction setup.
This was ridiculous. We were ignoring the inst->header.saturate flag in the case of math and only math. On gen4, we would leave inst->header.saturate in place if it happened to be set, which would end up being applied to the implicit mov and thus trash the first argument. On gen6, we would overwrite inst->header.saturate with the saturate flag from the argument, which was not set appropriately in brw_vec4_emit.cpp, and was only not a bug due to our incompetence at coalescing saturate moves. By ripping the argument out and making saturate work just like all the other brw_eu_emit.c code generation, we can avoid both these classes of bugs. Fixes piglit fog-modes, and the new specific fs-saturate-exp2 case. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=48628 NOTE: This is a candidate for the 8.0 branch. Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_sf_emit.c')
-rw-r--r--src/mesa/drivers/dri/i965/brw_sf_emit.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_sf_emit.c b/src/mesa/drivers/dri/i965/brw_sf_emit.c
index ff6383b..5f3673b 100644
--- a/src/mesa/drivers/dri/i965/brw_sf_emit.c
+++ b/src/mesa/drivers/dri/i965/brw_sf_emit.c
@@ -314,7 +314,6 @@ static void invert_det( struct brw_sf_compile *c)
brw_math(&c->func,
c->inv_det,
BRW_MATH_FUNCTION_INV,
- BRW_MATH_SATURATE_NONE,
0,
c->det,
BRW_MATH_DATA_SCALAR,
@@ -599,7 +598,6 @@ void brw_emit_point_sprite_setup(struct brw_sf_compile *c, bool allocate)
brw_math(&c->func,
c->tmp,
BRW_MATH_FUNCTION_INV,
- BRW_MATH_SATURATE_NONE,
0,
c->dx0,
BRW_MATH_DATA_SCALAR,