[llvm] [AArch64][SVE] Add partial reduction SDNodes (PR #117185)
Sander de Smalen via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 17 05:36:43 PST 2025
================
@@ -8135,15 +8135,19 @@ void SelectionDAGBuilder::visitIntrinsicCall(const CallInst &I,
return;
}
case Intrinsic::experimental_vector_partial_reduce_add: {
+ SDLoc dl = getCurSDLoc();
+ SDValue Acc = getValue(I.getOperand(0));
+ EVT AccVT = Acc.getValueType();
+ SDValue Input = getValue(I.getOperand(1));
if (!TLI.shouldExpandPartialReductionIntrinsic(cast<IntrinsicInst>(&I))) {
- visitTargetIntrinsic(I, Intrinsic);
+ setValue(&I, DAG.getNode(ISD::PARTIAL_REDUCE_UMLA, dl, AccVT, Acc, Input,
----------------
sdesmalen-arm wrote:
Did you arbitrarily choose the unsigned `UMLA` variant, because the element types of Input and Acc must be the same? If so, that's worth a comment describing that (and possibly also an assert).
https://github.com/llvm/llvm-project/pull/117185
More information about the llvm-commits
mailing list