ir3/ra: Always insert interval for precolored inputs
insert_dst checked whether dst is unused, however for precolored inputs we always want to reserve a reg for them. Input could be unused only if we explicitly want it. Suggested-by: Connor Abbott <cwabbott0@gmail.com> Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17771>
This commit is contained in:

committed by
Marge Bot

parent
ff8e52541d
commit
ed7814def7
@@ -1797,10 +1797,15 @@ handle_precolored_input(struct ra_ctx *ctx, struct ir3_instruction *instr)
|
||||
if (instr->dsts[0]->num == INVALID_REG)
|
||||
return;
|
||||
|
||||
struct ra_file *file = ra_get_file(ctx, instr->dsts[0]);
|
||||
struct ra_interval *interval = &ctx->intervals[instr->dsts[0]->name];
|
||||
physreg_t physreg = ra_reg_get_physreg(instr->dsts[0]);
|
||||
allocate_dst_fixed(ctx, instr->dsts[0], physreg);
|
||||
insert_dst(ctx, instr->dsts[0]);
|
||||
|
||||
d("insert precolored dst %u physreg %u", instr->dsts[0]->name,
|
||||
ra_interval_get_physreg(interval));
|
||||
|
||||
ra_file_insert(file, interval);
|
||||
interval->frozen = true;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user