summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/i965/brw_fs_cse.cpp5
-rw-r--r--src/mesa/state_tracker/st_glsl_to_tgsi.cpp6
2 files changed, 2 insertions, 9 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_fs_cse.cpp b/src/mesa/drivers/dri/i965/brw_fs_cse.cpp
index 7828c27e806..26873b8427d 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_cse.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs_cse.cpp
@@ -183,10 +183,7 @@ fs_visitor::opt_cse_local(bblock_t *block, exec_list *aeb)
{
bool found = false;
- aeb_entry *entry;
- foreach_list(entry_node, aeb) {
- entry = (aeb_entry *) entry_node;
-
+ foreach_in_list_use_after(aeb_entry, entry, aeb) {
/* Match current instruction's expression against those in AEB. */
if (instructions_match(inst, entry->generator)) {
found = true;
diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
index 1f89ca57364..9e194313942 100644
--- a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
+++ b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
@@ -2660,11 +2660,7 @@ glsl_to_tgsi_visitor::visit(ir_constant *ir)
function_entry *
glsl_to_tgsi_visitor::get_function_signature(ir_function_signature *sig)
{
- function_entry *entry;
-
- foreach_list(node, &this->function_signatures) {
- entry = (function_entry *) node;
-
+ foreach_in_list_use_after(function_entry, entry, &this->function_signatures) {
if (entry->sig == sig)
return entry;
}