summaryrefslogtreecommitdiff
path: root/src/panfrost/midgard
diff options
context:
space:
mode:
authorAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>2020-10-14 20:38:43 -0400
committerMarge Bot <eric+marge@anholt.net>2020-10-23 14:48:23 +0000
commitd2bfcba54d8138a848b5d2763a0eb405f18a949c (patch)
tree1d73ce9349371b72280e773f147bcaa2ddcb637b /src/panfrost/midgard
parentb19d9c86a878d71473d24cc4cabb606a09e35b68 (diff)
pan/mdg: Cleanup mir_rewrite_index_src_single
Use idiomatic iterator. Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7206>
Diffstat (limited to 'src/panfrost/midgard')
-rw-r--r--src/panfrost/midgard/mir.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/panfrost/midgard/mir.c b/src/panfrost/midgard/mir.c
index 069b8758393..9dfba6fec1b 100644
--- a/src/panfrost/midgard/mir.c
+++ b/src/panfrost/midgard/mir.c
@@ -26,7 +26,7 @@
void mir_rewrite_index_src_single(midgard_instruction *ins, unsigned old, unsigned new)
{
- for (unsigned i = 0; i < ARRAY_SIZE(ins->src); ++i) {
+ mir_foreach_src(ins, i) {
if (ins->src[i] == old)
ins->src[i] = new;
}