mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 06:48:06 +02:00
aco/ra: don't write to scc/ttmp with s_fmac
Fixes: 4bd229ac50 ("aco/gfx11.5: select SOP2 float instructions")
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32545>
This commit is contained in:
parent
0b9e2a5427
commit
65506e635b
1 changed files with 8 additions and 1 deletions
|
|
@ -2091,7 +2091,14 @@ operand_can_use_reg(amd_gfx_level gfx_level, aco_ptr<Instruction>& instr, unsign
|
|||
gfx_level >= GFX10); /* sdata can be vcc */
|
||||
case Format::MUBUF:
|
||||
case Format::MTBUF: return idx != 2 || gfx_level < GFX12 || reg != scc;
|
||||
case Format::SOPK: return idx != 0 || reg != scc;
|
||||
case Format::SOPK:
|
||||
if (idx == 0 && reg == scc)
|
||||
return false;
|
||||
FALLTHROUGH;
|
||||
case Format::SOP2:
|
||||
case Format::SOP1:
|
||||
return get_op_fixed_to_def(instr.get()) != (int)idx ||
|
||||
is_sgpr_writable_without_side_effects(gfx_level, reg);
|
||||
default:
|
||||
// TODO: there are more instructions with restrictions on registers
|
||||
return true;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue