summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i965
diff options
context:
space:
mode:
authorMatt Turner <[email protected]>2016-02-14 22:28:51 -0800
committerMatt Turner <[email protected]>2016-03-12 19:23:50 -0800
commit61b10b4eb73dcfd12f99ffa43e703429344c9435 (patch)
treeab14c07d1d593102059268abdcbfc98d989518dc /src/mesa/drivers/dri/i965
parent98d58e73204a9ba84fb70ad29651659399dcc8bd (diff)
i965: Use foreach_in_list_reverse_safe() macro.
Reviewed-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/i965')
-rw-r--r--src/mesa/drivers/dri/i965/brw_schedule_instructions.cpp14
1 files changed, 2 insertions, 12 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_schedule_instructions.cpp b/src/mesa/drivers/dri/i965/brw_schedule_instructions.cpp
index 4f97577515a..5b54b51395c 100644
--- a/src/mesa/drivers/dri/i965/brw_schedule_instructions.cpp
+++ b/src/mesa/drivers/dri/i965/brw_schedule_instructions.cpp
@@ -1057,12 +1057,7 @@ fs_instruction_scheduler::calculate_deps()
last_accumulator_write = NULL;
last_fixed_grf_write = NULL;
- exec_node *node;
- exec_node *prev;
- for (node = instructions.get_tail(), prev = node->prev;
- !node->is_head_sentinel();
- node = prev, prev = node->prev) {
- schedule_node *n = (schedule_node *)node;
+ foreach_in_list_reverse_safe(schedule_node, n, &instructions) {
fs_inst *inst = (fs_inst *)n->inst;
/* write-after-read deps. */
@@ -1284,12 +1279,7 @@ vec4_instruction_scheduler::calculate_deps()
last_accumulator_write = NULL;
last_fixed_grf_write = NULL;
- exec_node *node;
- exec_node *prev;
- for (node = instructions.get_tail(), prev = node->prev;
- !node->is_head_sentinel();
- node = prev, prev = node->prev) {
- schedule_node *n = (schedule_node *)node;
+ foreach_in_list_reverse_safe(schedule_node, n, &instructions) {
vec4_instruction *inst = (vec4_instruction *)n->inst;
/* write-after-read deps. */