r600/sfn: remove obsolete index and address register handling

This old code was needed to get the backend assembler to do the
right thing when emitting index and address registers, but sfn
is handling this now so we can drop this.

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36101>
This commit is contained in:
Gert Wollny 2025-07-02 00:00:56 +02:00 committed by Marge Bot
parent 5d0719bf8d
commit c95b86cc0b

View file

@ -464,24 +464,7 @@ AssamblerVisitor::visit(const AluGroup& group)
}
auto [addr, is_index] = group.addr();
if (addr) {
if (!addr->has_flag(Register::addr_or_idx)) {
if (is_index) {
emit_index_reg(*addr, 0);
} else {
auto reg = addr->as_register();
assert(reg);
if (!m_last_addr || !m_bc->ar_loaded || !m_last_addr->equal_to(*reg)) {
m_last_addr = reg;
m_bc->ar_reg = reg->sel();
m_bc->ar_chan = reg->chan();
m_bc->ar_loaded = 0;
r600_load_ar(m_bc, group.addr_for_src());
}
}
}
}
assert(!addr || addr->has_flag(Register::addr_or_idx));
for (auto& i : group) {
if (i)
@ -1199,13 +1182,6 @@ AssamblerVisitor::copy_dst(r600_bytecode_alu_dst& dst, const Register& d, bool w
if (m_last_addr && m_last_addr->equal_to(d))
m_last_addr = nullptr;
for (int i = 0; i < 2; ++i) {
/* Force emitting index register, if we didn't emit it yet, because
* the register value will change now */
if (dst.sel == m_bc->index_reg[i] && dst.chan == m_bc->index_reg_chan[i])
m_bc->index_loaded[i] = false;
}
return true;
}