The STRICT was causing unnecessary confusion. I think SEQ is a more accurate name for what they actually do, and the other obvious option of "ORDERED" has the issue of already having a meaning in FP contexts.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
AArch64 calls these "strictly-ordered reductions". If those two words are off the table then SEQ sounds fine to me providing we explain what that means (which we do).
llvm/include/llvm/CodeGen/ISDOpcodes.h | ||
---|---|---|
1109–1124 | -> These reductions are not strictly ordered, ... |
The STRICT was causing unnecessary confusion. I think SEQ is a more accurate name for what they actually do, and the other obvious option of "ORDERED" has the issue of already having a meaning in FP contexts.
Out of curiosity, what is the existing usage of "ordered" that conflicts with this one?
llvm/include/llvm/CodeGen/ISDOpcodes.h | ||
---|---|---|
1108–1109 | To avoid ambiguity - please can you add a codesnippet to the comment showing the order? Maybe something similar to relaxed variants below showing possible expansions (and maybe what the default legalizing expansion is?). |
Ordered FP comparisons, e.g. the "oeq" condition code.
llvm/include/llvm/CodeGen/ISDOpcodes.h | ||
---|---|---|
1108–1109 | Sure, will do. |
llvm/include/llvm/CodeGen/ISDOpcodes.h | ||
---|---|---|
1120–1122 | We are nitpicking at this point, but should it be using updated variables: /// PART_RDX = FADD SRC_VEC[0:3], SRC_VEC[4:7] /// PART_RDX2 = FADD PART_RDX[0:1], PART_RDX[2:3] /// RES = FADD PART_RDX2[0], PART_RDX2[1] |
Remove the scalar input overload for fadd/fmul. Now the signature is simple llvm.reduce.fadd.v4f32 rather than llvm.reduce.fadd.f32.v4f32
Also fix some langref formatting, and fold in the change to use "sequential" instead of "ordered" while I'm there.
Sigh, attached patch to wrong review. Ignore that update, reverting to earlier version.
To avoid ambiguity - please can you add a codesnippet to the comment showing the order? Maybe something similar to relaxed variants below showing possible expansions (and maybe what the default legalizing expansion is?).