freedreno/ir3: add iterator macros
[mesa.git] / src / freedreno / ir3 / ir3_a6xx.c
index 457b20d00716d84861a53aa6707fc4b46d3c7b20..fe3355bf2eb31f518905e9dca92b97724cc7a8ef 100644 (file)
@@ -386,14 +386,14 @@ ir3_a6xx_fixup_atomic_dests(struct ir3 *ir, struct ir3_shader_variant *so)
        if (so->image_mapping.num_ibo == 0)
                return;
 
-       list_for_each_entry (struct ir3_block, block, &ir->block_list, node) {
-               list_for_each_entry (struct ir3_instruction, instr, &block->instr_list, node) {
+       foreach_block (block, &ir->block_list) {
+               foreach_instr (instr, &block->instr_list) {
                        instr->data = NULL;
                }
        }
 
-       list_for_each_entry (struct ir3_block, block, &ir->block_list, node) {
-               list_for_each_entry_safe (struct ir3_instruction, instr, &block->instr_list, node) {
+       foreach_block (block, &ir->block_list) {
+               foreach_instr_safe (instr, &block->instr_list) {
                        struct ir3_register *reg;
 
                        foreach_src(reg, instr) {