freedreno/ir3/ra: fix array liveranges
authorRob Clark <robdclark@chromium.org>
Sun, 22 Mar 2020 19:37:12 +0000 (12:37 -0700)
committerMarge Bot <eric+marge@anholt.net>
Fri, 27 Mar 2020 22:41:36 +0000 (22:41 +0000)
Fixes: 1b658533e11 ("freedreno/ir3: extend liverange of arrays")
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4272>

src/freedreno/ir3/ir3_ra.c

index fa379c3495b9c95eaf7a43075c34ce1b8228b63b..a26c5914f8e0178eac2bce15f4ca560dd565ce0b 100644 (file)
@@ -795,7 +795,7 @@ ra_add_interference(struct ir3_ra_ctx *ctx)
                                if (BITSET_TEST(bd->livein, i + arr->base)) {
                                        arr->start_ip = MIN2(arr->start_ip, block->start_ip);
                                }
-                               if (BITSET_TEST(bd->livein, i + arr->base)) {
+                               if (BITSET_TEST(bd->liveout, i + arr->base)) {
                                        arr->end_ip = MAX2(arr->end_ip, block->end_ip);
                                }
                        }