Skip to content

Commit 9257fd0

Browse files
committed
Revert new add/sub narrowing conditional to avoid test failures for now
1 parent 5b150a8 commit 9257fd0

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

llvm/lib/Target/Z80/GISel/Z80LegalizerInfo.cpp

+2-3
Original file line numberDiff line numberDiff line change
@@ -428,9 +428,8 @@ Z80LegalizerInfo::legalizeAddSub(LegalizerHelper &Helper, MachineInstr &MI,
428428
}
429429
if (LegalSize)
430430
return LegalizerHelper::Legalized;
431-
if ((!F.hasOptSize() || MI.getOpcode() == G_ADD) &&
432-
Size == (Subtarget.is24Bit() ? 48 : 32))
433-
return Helper.narrowScalar(MI, 0, LLT::scalar(Size / 2));
431+
if (Subtarget.is24Bit() && Size == 48)
432+
return Helper.narrowScalar(MI, 0, LLT::scalar(24));
434433
return Helper.libcall(MI, LocObserver);
435434
}
436435

0 commit comments

Comments
 (0)