OSDN Git Service
(root)
/
android-x86
/
external-mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ea21341
)
i965: Fix a weirdness in NOT handling.
author
Eric Anholt
<eric@anholt.net>
Mon, 18 Oct 2010 18:13:26 +0000
(11:13 -0700)
committer
Eric Anholt
<eric@anholt.net>
Mon, 18 Oct 2010 19:56:44 +0000
(12:56 -0700)
XOR makes much more sense. Note that the previous code would have
failed for not(not(x)), but that gets optimized out.
src/mesa/drivers/dri/i965/brw_fs.cpp
patch
|
blob
|
history
diff --git
a/src/mesa/drivers/dri/i965/brw_fs.cpp
b/src/mesa/drivers/dri/i965/brw_fs.cpp
index
c9e1098
..
2224dc7
100644
(file)
--- a/
src/mesa/drivers/dri/i965/brw_fs.cpp
+++ b/
src/mesa/drivers/dri/i965/brw_fs.cpp
@@
-720,7
+720,7
@@
fs_visitor::visit(ir_expression *ir)
/* Note that BRW_OPCODE_NOT is not appropriate here, since it is
* ones complement of the whole register, not just bit 0.
*/
- emit(fs_inst(BRW_OPCODE_
ADD, this->result, op[0], fs_reg(-
1)));
+ emit(fs_inst(BRW_OPCODE_
XOR, this->result, op[0], fs_reg(
1)));
break;
case ir_unop_neg:
op[0].negate = !op[0].negate;