[Mesa-dev] [PATCH 03/15] i965/cfg: Rework to make IF & ELSE blocks flow into ENDIF.
Matt Turner
mattst88 at gmail.com
Mon Dec 2 13:43:59 PST 2013
And since this change makes ENDIF start blocks, I'll squash this
change in as well to make sure dead_control_flow_eliminate continues
working:
diff --git a/src/mesa/drivers/dri/i965/brw_dead_control_flow.cpp
b/src/mesa/drivers/dri/i965/brw_dead_control_flow.cpp
index ad8ed82..63a3e5b 100644
--- a/src/mesa/drivers/dri/i965/brw_dead_control_flow.cpp
+++ b/src/mesa/drivers/dri/i965/brw_dead_control_flow.cpp
@@ -45,10 +45,10 @@ dead_control_flow_eliminate(backend_visitor *v)
bblock_t *block = cfg.blocks[b];
bool found = false;
- /* ENDIF instructions, by definition, can only be found at the ends of
+ /* ENDIF instructions, by definition, can only be found at the start of
* basic blocks.
*/
- backend_instruction *endif_inst = block->end;
+ backend_instruction *endif_inst = block->start;
if (endif_inst->opcode != BRW_OPCODE_ENDIF)
continue;
More information about the mesa-dev
mailing list