diff --git a/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp b/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp index 7b51f453b4974..5b24ee302de5c 100644 --- a/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp +++ b/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp @@ -2556,7 +2556,7 @@ bool AArch64TargetLowering::targetShrinkDemandedConstant( return false; // Exit early if we demand all bits. - if (DemandedBits.popcount() == Size) + if (DemandedBits.isAllOnes()) return false; unsigned NewOpc;