mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 04:58:05 +02: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>
(cherry picked from commit 2d36232e62)
This commit is contained in:
parent
7ab251c71a
commit
0c5b2aa429
2 changed files with 5 additions and 3 deletions
|
|
@ -247,7 +247,7 @@
|
|||
"description": "aco: allow SDWA sels smaller than the operand size",
|
||||
"nominated": true,
|
||||
"nomination_type": 0,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"master_sha": null,
|
||||
"because_sha": null
|
||||
},
|
||||
|
|
|
|||
|
|
@ -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