summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorConnor Abbott <cwabbott0@gmail.com>2021-06-18 12:49:05 +0200
committerMarge Bot <eric+marge@anholt.net>2021-06-23 17:20:29 +0000
commitdce680737ddb200c59c55a8c696114f793757398 (patch)
treea7e678bb166f8f2afa9a835e72380fb251ec3222 /src
parentef7bc4a2aa6b0a0063a478499f74a85cf3ef1dd1 (diff)
ir3: Validate that ir3_register::instr is correct
Catch the mistake fixed in the previous commit. Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11469>
Diffstat (limited to 'src')
-rw-r--r--src/freedreno/ir3/ir3_validate.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/freedreno/ir3/ir3_validate.c b/src/freedreno/ir3/ir3_validate.c
index 68e931dd619..7100cb392f7 100644
--- a/src/freedreno/ir3/ir3_validate.c
+++ b/src/freedreno/ir3/ir3_validate.c
@@ -121,6 +121,9 @@ validate_reg(struct ir3_validate_ctx *ctx, struct ir3_instruction *instr,
}
validate_assert(ctx, found && "tied register not in the same instruction");
}
+
+ if ((reg->flags & IR3_REG_DEST) && (reg->flags & IR3_REG_SSA))
+ validate_assert(ctx, reg->instr == instr);
}
#define validate_reg_size(ctx, reg, type) \