i965: Add a second successor to BRW_OPCODE_WHILE

It is possible to directly predicate the WHILE instruction. In this
case there will be a second successor block because the execution can
resume from the instruction after the loop. This will be used in a
subsequent patch.

Reviewed-by: Matt Turner <mattst88@gmail.com>
This commit is contained in:
Neil Roberts 2015-10-05 13:50:56 +02:00
parent 886d46b089
commit 728d7bc85f

View file

@ -305,6 +305,10 @@ cfg_t::cfg_t(exec_list *instructions)
assert(cur_do != NULL && cur_while != NULL);
cur->add_successor(mem_ctx, cur_do);
if (inst->predicate)
cur->add_successor(mem_ctx, cur_while);
set_next_block(&cur, cur_while, ip);
/* Pop the stack so we're in the previous loop */