Mesa (gallium-resources): Revert "i965: Do FS SLT, SGT, and friends using CMP, SEL instead of CMP, MOV, MOV."
Keith Whitwell
keithw at kemper.freedesktop.org
Wed Mar 17 08:46:59 UTC 2010
Module: Mesa
Branch: gallium-resources
Commit: ba208604ea8bc069be583732a4c59a47e4a7b280
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=ba208604ea8bc069be583732a4c59a47e4a7b280
Author: Eric Anholt <eric at anholt.net>
Date: Tue Mar 16 11:22:29 2010 -0700
Revert "i965: Do FS SLT, SGT, and friends using CMP, SEL instead of CMP, MOV, MOV."
This reverts commit 46450c1f3f93bf4dc96696fc7e0f0eb808d9c08a. I was
wrong about null reg behavior -- it reads undefined, not 0. And
they're not kidding.
---
src/mesa/drivers/dri/i965/brw_wm_emit.c | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_wm_emit.c b/src/mesa/drivers/dri/i965/brw_wm_emit.c
index 05e464d..1869fd0 100644
--- a/src/mesa/drivers/dri/i965/brw_wm_emit.c
+++ b/src/mesa/drivers/dri/i965/brw_wm_emit.c
@@ -545,8 +545,11 @@ void emit_sop(struct brw_compile *p,
for (i = 0; i < 4; i++) {
if (mask & (1<<i)) {
brw_push_insn_state(p);
- brw_CMP(p, brw_null_reg(), cond, arg1[i], arg0[i]);
- brw_SEL(p, dst[i], brw_null_reg(), brw_imm_f(1.0));
+ brw_CMP(p, brw_null_reg(), cond, arg0[i], arg1[i]);
+ brw_set_predicate_control(p, BRW_PREDICATE_NONE);
+ brw_MOV(p, dst[i], brw_imm_f(0));
+ brw_set_predicate_control(p, BRW_PREDICATE_NORMAL);
+ brw_MOV(p, dst[i], brw_imm_f(1.0));
brw_pop_insn_state(p);
}
}
More information about the mesa-commit
mailing list