aco: don't label mul with opsel as abs/neg

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22069>
This commit is contained in:
Georg Lehmann
2023-03-24 13:35:07 +01:00
committed by Marge Bot
parent ace017bba8
commit 3907c54443

View File

@@ -1840,7 +1840,7 @@ label_instruction(opt_ctx& ctx, aco_ptr<Instruction>& instr)
for (unsigned i = 0; i < 2; i++) {
if (instr->operands[!i].isConstant() && instr->operands[i].isTemp()) {
if (!instr->isDPP() && !instr->isSDWA() &&
if (!instr->isDPP() && !instr->isSDWA() && !instr->valu().opsel &&
(instr->operands[!i].constantEquals(fp16 ? 0x3c00 : 0x3f800000) || /* 1.0 */
instr->operands[!i].constantEquals(fp16 ? 0xbc00 : 0xbf800000u))) { /* -1.0 */
bool neg1 = instr->operands[!i].constantEquals(fp16 ? 0xbc00 : 0xbf800000u);