[PATCH] D143283: [AArch64][SVE]: custom lower AVGFloor/AVGCeil.
hassnaaHamdi via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 28 04:53:12 PST 2023
hassnaa-arm added inline comments.
================
Comment at: llvm/lib/Target/AArch64/AArch64ISelLowering.cpp:13391
+ if (ISD::isConstantSplatVector(Node.getOperand(1).getNode(), SplatVal))
+ if (SplatVal.isMask() && SplatVal.countPopulation() <
+ Node->getValueType(0).getScalarSizeInBits())
----------------
dmgreen wrote:
> Can it use countTrailingOnes as opposed to countPopulation? Although I think these functions might be better removed and use computeKnownBits checks instead.
I think using countTrailingOnes is much simpler than computeKnownBits because the operand and its value are already known.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D143283/new/
https://reviews.llvm.org/D143283
More information about the llvm-commits
mailing list