[Mlir-commits] [mlir] [mlir][tensor] Fold producer linalg transpose with consumer tensor pack (PR #75658)
lorenzo chelini
llvmlistbot at llvm.org
Thu Dec 28 07:03:35 PST 2023
================
@@ -21,6 +21,57 @@ static bool areAllConstantIntValue(ArrayRef<OpFoldResult> ofrs, int64_t value) {
ofrs, [&](OpFoldResult ofr) { return isConstantIntValue(ofr, value); });
}
+/// Helper function to generate an equivalent permutation map for
+/// `linalg.transpose` and `tensor.pack` which will be used after their folding
+/// into a `tensor.pack`.
+static bool getRemappedPermutationForTransposeAndPack(
----------------
chelini wrote:
Sorry I may have confused you with this comment. What I mentioned above is true as long as the transpose do not rearrange the loop ids in `inner_dims_pos`.
https://github.com/llvm/llvm-project/pull/75658
More information about the Mlir-commits
mailing list