[llvm] [SelectionDAG] Add SDTCisInt<1>/SDTCisFP<1> to SDTVecReduce/SDTFPVecReduce. NFC (PR #162761)
Sergei Barannikov via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 9 19:10:55 PDT 2025
================
@@ -300,10 +300,10 @@ def SDTVecInsert : SDTypeProfile<1, 3, [ // vector insert
SDTCisEltOfVec<2, 1>, SDTCisSameAs<0, 1>, SDTCisPtrTy<3>
]>;
def SDTVecReduce : SDTypeProfile<1, 1, [ // vector reduction
- SDTCisInt<0>, SDTCisVec<1>
+ SDTCisInt<0>, SDTCisVec<1>, SDTCisInt<1>
]>;
def SDTFPVecReduce : SDTypeProfile<1, 1, [ // FP vector reduction
- SDTCisFP<0>, SDTCisVec<1>
+ SDTCisFP<0>, SDTCisVec<1>, SDTCisFP<1>
----------------
s-barannikov wrote:
---
Can this be:
```suggestion
SDTCisEltOfVec<0, 1>, SDTCisVec<1>, SDTCisFP<1>
```
Corresponding LLVM intrinsics require the result type to match the source element type, but I don't know if this is still a requirement in SDAG.
https://github.com/llvm/llvm-project/pull/162761
More information about the llvm-commits
mailing list