projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c2014f0
)
ir_to_mesa: Don't assert over assignments with a constant-true condition.
author
Eric Anholt
<eric@anholt.net>
Wed, 19 May 2010 23:06:37 +0000
(16:06 -0700)
committer
Eric Anholt
<eric@anholt.net>
Thu, 24 Jun 2010 22:05:21 +0000
(15:05 -0700)
ir_to_mesa.cpp
patch
|
blob
|
history
diff --git
a/ir_to_mesa.cpp
b/ir_to_mesa.cpp
index edc95eb5caa800f33dcd4ea80a9053a67790455a..4238d9a8c81489bb0a3d48026d45a3106befafdf 100644
(file)
--- a/
ir_to_mesa.cpp
+++ b/
ir_to_mesa.cpp
@@
-824,7
+824,13
@@
ir_to_mesa_visitor::visit(ir_assignment *ir)
assert(l);
assert(r);
- assert(!ir->condition);
+ if (ir->condition) {
+ ir_constant *condition_constant;
+
+ condition_constant = ir->condition->constant_expression_value();
+
+ assert(condition_constant && condition_constant->value.b[0]);
+ }
t = this->create_tree(MB_TERM_assign, ir, l, r);
mono_burg_label(t, NULL);