[clang] [clang][clangir] add vpaddl and vpaddlq support (PR #191845)
Andrzej WarzyĆski via cfe-commits
cfe-commits at lists.llvm.org
Thu Apr 16 04:07:22 PDT 2026
================
@@ -196,6 +196,40 @@ static mlir::Value emitNeonCall(CIRGenModule &cgm, CIRGenBuilderTy &builder,
isConstrainedFPIntrinsic, shift, rightshift);
}
+static cir::VectorType getVPaddlInputVectorType(cir::VectorType resType,
+ bool usgn) {
+ mlir::Type elemTy = resType.getElementType();
+ uint64_t lanes = resType.getSize();
+ auto intTy = mlir::dyn_cast<cir::IntType>(elemTy);
+ if (!intTy) {
+ llvm_unreachable("vpaddl result type must be an integer vector");
+ }
----------------
banach-space wrote:
I would use plain assert in this case.
```suggestion
assert(intTy && "vpaddl result type must be an integer vector");
```
https://github.com/llvm/llvm-project/pull/191845
More information about the cfe-commits
mailing list