projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8645a95
)
Add support for bool to ir_equal and ir_nequal constant handling
author
Ian Romanick
<ian.d.romanick@intel.com>
Wed, 7 Apr 2010 23:48:42 +0000
(16:48 -0700)
committer
Ian Romanick
<ian.d.romanick@intel.com>
Wed, 7 Apr 2010 23:49:25 +0000
(16:49 -0700)
ir_constant_expression.cpp
patch
|
blob
|
history
diff --git
a/ir_constant_expression.cpp
b/ir_constant_expression.cpp
index 7e1bb030f57c553faebcdf0f5e415faead14bb33..e3a0d9eaa11645837f7cecd2231a7c86cf2429a3 100644
(file)
--- a/
ir_constant_expression.cpp
+++ b/
ir_constant_expression.cpp
@@
-355,6
+355,9
@@
ir_constant_visitor::visit(ir_expression *ir)
case GLSL_TYPE_FLOAT:
b[0] = b[0] && op[0]->value.f[c] == op[1]->value.f[c];
break;
+ case GLSL_TYPE_BOOL:
+ b[0] = b[0] && op[0]->value.b[c] == op[1]->value.b[c];
+ break;
default:
assert(0);
}
@@
-376,6
+379,9
@@
ir_constant_visitor::visit(ir_expression *ir)
case GLSL_TYPE_FLOAT:
b[0] = b[0] || op[0]->value.f[c] != op[1]->value.f[c];
break;
+ case GLSL_TYPE_BOOL:
+ b[0] = b[0] || op[0]->value.b[c] != op[1]->value.b[c];
+ break;
default:
assert(0);
}