summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlyssa Rosenzweig <[email protected]>2019-08-15 14:23:05 -0700
committerAlyssa Rosenzweig <[email protected]>2019-08-19 08:32:17 -0700
commit739e09c2974533a119d341020166e95f4ef0f604 (patch)
treeb18bfab2c6e7d3a65dd227f090215db9d476d67e
parent6f1c8c148d01974f1ea99c59482d92944aaad438 (diff)
pan/midgard: Fix texw lowering with complex control flow
Fixes shaders with control flow like: out = 0; if (A) { if (B) out = texture(A, ...) } else { out = texture(B, ...) } Signed-off-by: Alyssa Rosenzweig <[email protected]>
-rw-r--r--src/panfrost/midgard/midgard_ra.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/panfrost/midgard/midgard_ra.c b/src/panfrost/midgard/midgard_ra.c
index 4754971acb2..5df8ecf0df0 100644
--- a/src/panfrost/midgard/midgard_ra.c
+++ b/src/panfrost/midgard/midgard_ra.c
@@ -497,7 +497,7 @@ mir_lower_special_reads(compiler_context *ctx)
midgard_instruction *use = mir_next_op(pre_use);
assert(use);
mir_insert_instruction_before(use, m);
- mir_rewrite_index_dst_tag(ctx, i, idx, classes[j]);
+ mir_rewrite_index_dst_single(pre_use, i, idx);
} else {
idx = spill_idx++;
m = v_mov(i, blank_alu_src, idx);