r300: fix presubtract assert
We only care that the negates of the relevant components are the same. Specifically the assert would incorectly trigger for code like this ADD temp[3].x, 1.250000 (0x3a).-x___, -const[0].x___; Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com> Reviewed-by: Filip Gawin <None> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33066>
This commit is contained in:
committed by
Marge Bot
parent
b23ff87db4
commit
ea41ecd130
@@ -374,7 +374,9 @@ presub_replace_add(struct rc_instruction *inst_add, struct rc_instruction *inst_
|
||||
negates++;
|
||||
if (inst_add->U.I.SrcReg[1].Negate)
|
||||
negates++;
|
||||
assert(negates != 2 || inst_add->U.I.SrcReg[1].Negate == inst_add->U.I.SrcReg[0].Negate);
|
||||
assert(negates != 2 ||
|
||||
((inst_add->U.I.SrcReg[1].Negate & inst_add->U.I.DstReg.WriteMask) ==
|
||||
(inst_add->U.I.SrcReg[0].Negate & inst_add->U.I.DstReg.WriteMask)));
|
||||
|
||||
if (negates == 1)
|
||||
presub_opcode = RC_PRESUB_SUB;
|
||||
|
||||
Reference in New Issue
Block a user