__node = __next, __next = \
exec_node_data(__type, (__next)->__field.next, __field))
-#define foreach_list_typed_safe_reverse(__type, __node, __field, __list) \
+#define foreach_list_typed_reverse_safe(__type, __node, __field, __list) \
for (__type * __node = \
exec_node_data(__type, (__list)->tail_pred, __field), \
* __prev = \
foreach_if(nir_if *if_stmt, nir_foreach_block_cb cb, bool reverse, void *state)
{
if (reverse) {
- foreach_list_typed_safe_reverse(nir_cf_node, node, node,
+ foreach_list_typed_reverse_safe(nir_cf_node, node, node,
&if_stmt->else_list) {
if (!foreach_cf_node(node, cb, reverse, state))
return false;
}
- foreach_list_typed_safe_reverse(nir_cf_node, node, node,
+ foreach_list_typed_reverse_safe(nir_cf_node, node, node,
&if_stmt->then_list) {
if (!foreach_cf_node(node, cb, reverse, state))
return false;
foreach_loop(nir_loop *loop, nir_foreach_block_cb cb, bool reverse, void *state)
{
if (reverse) {
- foreach_list_typed_safe_reverse(nir_cf_node, node, node, &loop->body) {
+ foreach_list_typed_reverse_safe(nir_cf_node, node, node, &loop->body) {
if (!foreach_cf_node(node, cb, reverse, state))
return false;
}
if (!cb(impl->end_block, state))
return false;
- foreach_list_typed_safe_reverse(nir_cf_node, node, node, &impl->body) {
+ foreach_list_typed_reverse_safe(nir_cf_node, node, node, &impl->body) {
if (!foreach_cf_node(node, cb, true, state))
return false;
}
foreach_list_typed_reverse(nir_instr, instr, node, &(block)->instr_list)
#define nir_foreach_instr_safe(block, instr) \
foreach_list_typed_safe(nir_instr, instr, node, &(block)->instr_list)
-#define nir_foreach_instr_safe_reverse(block, instr) \
- foreach_list_typed_safe_reverse(nir_instr, instr, node, &(block)->instr_list)
+#define nir_foreach_instr_reverse_safe(block, instr) \
+ foreach_list_typed_reverse_safe(nir_instr, instr, node, &(block)->instr_list)
typedef struct nir_if {
nir_cf_node cf_node;