[llvm] [SelectionDAG] Add PARTIAL_REDUCE_U/SMLA ISD Nodes (PR #125207)
James Chesterman via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 4 07:00:03 PST 2025
================
@@ -5624,7 +5624,14 @@ class TargetLowering : public TargetLoweringBase {
// Expands PARTIAL_REDUCE_S/UMLA nodes to a series of simpler operations,
// consisting of zext/sext, extract_subvector, mul and add operations.
- SDValue expandPartialReduceMLA(SDNode *N, SelectionDAG &DAG) const;
+ SDValue expandPartialReduceMLA(SDLoc DL, SDValue Acc, SDValue Input1,
+ SDValue Input2, SelectionDAG &DAG) const;
+
+ // Create the DAG equivalent of vector_partial_reduce where Op1 and Op2 are
+ // its operands and ReducedTY is the return type.
+ static SDValue getPartialReduceAdd(SDLoc DL, EVT ReducedTy, EVT FullTy,
+ SDValue Op1, SDValue Op2,
+ SelectionDAG &DAG);
----------------
JamesChesterman wrote:
Done, sorry I misunderstood, I thought we might have wanted to keep the two functions separate for now and have the new code path follow the `expandPartialReduceMLA()` function. But I understand now that they would do the same thing, so I've just combined the two functions into the `expandPartialReduceMLA()` function.
https://github.com/llvm/llvm-project/pull/125207
More information about the llvm-commits
mailing list