mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 17:30:12 +01:00
aco: allow SDWA sels smaller than the operand size
p_extract_vector copy-propagation can create byte sels for v2b operands. Signed-off-by: Rhys Perry <pendingchaos02@gmail.com> Reviewed-by: Daniel Schürmann <daniel@schuermann.dev> Cc: mesa-stable Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10315>
This commit is contained in:
parent
655ba1e3a9
commit
2d36232e62
1 changed files with 4 additions and 2 deletions
|
|
@ -549,8 +549,10 @@ bool validate_subdword_operand(chip_class chip, const aco_ptr<Instruction>& inst
|
|||
return byte == 0;
|
||||
if (instr->isPseudo() && chip >= GFX8)
|
||||
return true;
|
||||
if (instr->isSDWA() && (instr->sdwa().sel[index] & sdwa_asuint) == (sdwa_isra | op.bytes()))
|
||||
return true;
|
||||
if (instr->isSDWA()) {
|
||||
unsigned sel = instr->sdwa().sel[index] & sdwa_asuint;
|
||||
return (sel & sdwa_isra) && (sel & sdwa_rasize) <= op.bytes();
|
||||
}
|
||||
if (byte == 2 && can_use_opsel(chip, instr->opcode, index, 1))
|
||||
return true;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue