glsl2: Define new ir_discard instruction.

This commit is contained in:
Kenneth Graunke
2010-06-30 10:47:34 -07:00
committed by Ian Romanick
parent 88c20c46b8
commit 16efab1c4d
11 changed files with 115 additions and 0 deletions

View File

@@ -314,6 +314,20 @@ ir_print_visitor::visit(ir_return *ir)
}
void
ir_print_visitor::visit(ir_discard *ir)
{
printf("(discard ");
if (ir->condition != NULL) {
printf(" ");
ir->condition->accept(this);
}
printf(")");
}
void
ir_print_visitor::visit(ir_if *ir)
{