aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp
diff options
context:
space:
mode:
authorMatt Turner <[email protected]>2014-05-12 14:40:40 -0700
committerMatt Turner <[email protected]>2014-05-15 15:45:40 -0700
commit58bcf5996dc60043eee5946a6f2f96256768fc9f (patch)
treea188741f3a9bd7c43ca83d1eeca5540125736a1b /src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp
parenta77023c992fa37c609be56869c1bb5c00ec294b9 (diff)
i965/cfg: Embed exec_node in bblock_link.
In order to remove bblock_link's inheritance of exec_node. Also makes linked list walk code much nicer. Acked-by: Eric Anholt <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp')
-rw-r--r--src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp b/src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp
index a148c5473b7..069b60fe22a 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp
@@ -232,8 +232,7 @@ fs_copy_prop_dataflow::run()
const BITSET_WORD old_livein = bd[b].livein[i];
bd[b].livein[i] = ~0u;
- foreach_list(block_node, &cfg->blocks[b]->parents) {
- bblock_link *link = (bblock_link *)block_node;
+ foreach_list_typed(bblock_link, link, link, &cfg->blocks[b]->parents) {
bblock_t *block = link->block;
bd[b].livein[i] &= bd[block->block_num].liveout[i];
}
@@ -252,8 +251,8 @@ fs_copy_prop_dataflow::dump_block_data() const
bblock_t *block = cfg->blocks[b];
fprintf(stderr, "Block %d [%d, %d] (parents ", block->block_num,
block->start_ip, block->end_ip);
- foreach_list(block_node, &block->parents) {
- bblock_t *parent = ((bblock_link *) block_node)->block;
+ foreach_list_typed(bblock_link, link, link, &block->parents) {
+ bblock_t *parent = link->block;
fprintf(stderr, "%d ", parent->block_num);
}
fprintf(stderr, "):\n");