mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-03 00:40:09 +01:00
nv50/ir: fix wrong check when optimizing MAD to SHLADD
Checking if MAD is supported is definitely wrong, and it's more likely a typo I introduced few days ago which breaks NV50 because SHLADD is not supported there. Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
This commit is contained in:
parent
0b10152b80
commit
28ecd3eac2
1 changed files with 1 additions and 1 deletions
|
|
@ -1030,7 +1030,7 @@ ConstantFolding::opnd(Instruction *i, ImmediateValue &imm0, int s)
|
|||
i->op = OP_ADD;
|
||||
} else
|
||||
if (s == 1 && !imm0.isNegative() && imm0.isPow2() &&
|
||||
target->isOpSupported(i->op, i->dType)) {
|
||||
target->isOpSupported(OP_SHLADD, i->dType)) {
|
||||
i->op = OP_SHLADD;
|
||||
imm0.applyLog2();
|
||||
i->setSrc(1, new_ImmediateValue(prog, imm0.reg.data.u32));
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue