[clang] [CIR] Implement builtin extractf (PR #170427)
Andy Kaylor via cfe-commits
cfe-commits at lists.llvm.org
Fri Dec 5 16:06:37 PST 2025
================
@@ -152,6 +152,40 @@ computeFullLaneShuffleMask(CIRGenFunction &cgf, const mlir::Value vec,
outIndices.resize(numElts);
}
+static mlir::Value getBoolMaskVecValue(CIRGenBuilderTy &builder,
+ mlir::Location loc, mlir::Value mask,
+ unsigned numElems) {
+
+ cir::BoolType boolTy = builder.getBoolTy();
+ auto maskTy = cir::VectorType::get(
+ boolTy, cast<cir::IntType>(mask.getType()).getWidth());
+ mlir::Value maskVec = builder.createBitcast(mask, maskTy);
+
+ if (numElems < 8) {
+ SmallVector<mlir::Attribute, 4> indices;
----------------
andykaylor wrote:
```suggestion
SmallVector<mlir::Attribute> indices;
```
https://github.com/llvm/llvm-project/pull/170427
More information about the cfe-commits
mailing list