Skip to content

Commit f1cbb3a

Browse files
committed
Update ARMISelLowering.cpp
1 parent efb0886 commit f1cbb3a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

llvm/lib/Target/ARM/ARMISelLowering.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20235,7 +20235,8 @@ bool ARMTargetLowering::targetShrinkDemandedConstant(
2023520235
}
2023620236

2023720237
// Don't optimize if it is legal already.
20238-
if (isLegalLogicalImmediate(Mask, Subtarget))
20238+
if (isLegalLogicalImmediate(Mask, Subtarget) ||
20239+
isLegalLogicalImmediate(~Mask, Subtarget))
2023920240
return false;
2024020241

2024120242
if (isLegalLogicalImmediate(ShrunkMask, Subtarget)) {

0 commit comments

Comments
 (0)