[Mlir-commits] [mlir] [mlir][x86] Decouple Accumulator from ADD-Based Vector Contractions (over loops) (PR #204327)
Arun Thangamani
llvmlistbot at llvm.org
Thu Jul 23 00:46:39 PDT 2026
================
@@ -144,6 +144,25 @@ inline ShuffleMasks getShuffleMasks(int64_t nonUnitDimAcc, bool isInt8Avx2) {
return {maskLo8, maskHi8};
}
+// Recursively follows single-use values through scf.yield operations
+// and returns the first non-yield user result in the contraction chain.
+Value contractionUsersAfterYield(Value v) {
+ if (v.getNumUses() != 1)
+ return nullptr;
+
+ OpOperand &use = *v.use_begin();
+ Operation *user = use.getOwner();
+
+ if (!isa<scf::YieldOp>(user))
+ return v;
----------------
arun-thmn wrote:
Okay, Added an extra check to return `nullptr`, if `v` is `null`.
https://github.com/llvm/llvm-project/pull/204327
More information about the Mlir-commits
mailing list