diff options
author | Connor Abbott <cwabbott0@gmail.com> | 2021-06-18 12:48:06 +0200 |
---|---|---|
committer | Marge Bot <eric+marge@anholt.net> | 2021-06-23 17:20:29 +0000 |
commit | ef7bc4a2aa6b0a0063a478499f74a85cf3ef1dd1 (patch) | |
tree | 20b895a9f1d4e53edf700824ad7a2845cf3f80d9 /src/freedreno | |
parent | 0f329ba10ae64a6c58d7945d8b1b3f19959878e2 (diff) |
ir3: Update ir3_register::instr when cloning instructions
We happened to not clone any SSA instructions, but we will once address
instructions start counting as SSA. Fix this oversight.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11469>
Diffstat (limited to 'src/freedreno')
-rw-r--r-- | src/freedreno/ir3/ir3.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/freedreno/ir3/ir3.c b/src/freedreno/ir3/ir3.c index fdc6184728f..72e58e8a727 100644 --- a/src/freedreno/ir3/ir3.c +++ b/src/freedreno/ir3/ir3.c @@ -438,6 +438,8 @@ struct ir3_instruction * ir3_instr_clone(struct ir3_instruction *instr) struct ir3_register *new_reg = ir3_reg_create(new_instr, reg->num, reg->flags); *new_reg = *reg; + if ((new_reg->flags & IR3_REG_DEST) && new_reg->instr) + new_reg->instr = new_instr; } return new_instr; |