summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlyssa Rosenzweig <alyssa@collabora.com>2021-07-26 18:22:03 -0400
committerMarge Bot <eric+marge@anholt.net>2021-07-28 00:26:06 +0000
commita6ccbf48e98f3cd85913b00fa191255ca307a600 (patch)
treea2ea98a994b43c08ba2d5c5956d42f04b08ad130 /src
parent30f8fb82c99dfbb45542196ed60c37e47b3f5d73 (diff)
pan/bi: Clarify the logic of bi_reconverge_branches
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12026>
Diffstat (limited to 'src')
-rw-r--r--src/panfrost/bifrost/bir.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/panfrost/bifrost/bir.c b/src/panfrost/bifrost/bir.c
index 7444d2e4dd0..fa45ee7d1f1 100644
--- a/src/panfrost/bifrost/bir.c
+++ b/src/panfrost/bifrost/bir.c
@@ -197,10 +197,10 @@ bi_reconverge_branches(bi_block *block)
if (block->successors[1])
return true;
+ /* Must have at least one successor */
struct bi_block *succ = block->successors[0];
assert(succ->predecessors);
- unsigned count = succ->predecessors->entries;
- /* Reconverge if there are multiple predecessors */
- return (count != 1);
+ /* Reconverge if the successor has multiple predecessors */
+ return (succ->predecessors->entries > 1);
}