[all-commits] [llvm/llvm-project] c0a354: [mlir][vector] Fix invalid IR in `ContractionOpLow...
Matthias Springer via All-commits
all-commits at lists.llvm.org
Tue Jan 16 00:40:37 PST 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: c0a354dfabfd1534bc6f992b242e5d0ea043120d
https://github.com/llvm/llvm-project/commit/c0a354dfabfd1534bc6f992b242e5d0ea043120d
Author: Matthias Springer <me at m-sp.org>
Date: 2024-01-16 (Tue, 16 Jan 2024)
Changed paths:
M mlir/lib/Dialect/Vector/Transforms/LowerVectorContract.cpp
M mlir/test/Dialect/Vector/vector-contract-to-outerproduct-matvec-transforms.mlir
R mlir/test/Dialect/Vector/vector-contract-to-outerproduct-transforms-unsupported.mlir
Log Message:
-----------
[mlir][vector] Fix invalid IR in `ContractionOpLowering` (#78130)
If a rewrite pattern returns "failure", it must not have modified the
IR. This commit fixes
`Dialect/Vector/vector-contract-to-outerproduct-transforms-unsupported.mlir`
when running with `MLIR_ENABLE_EXPENSIVE_PATTERN_API_CHECKS`.
```
* Pattern (anonymous namespace)::ContractionOpToOuterProductOpLowering : 'vector.contract -> ()' {
Trying to match "(anonymous namespace)::ContractionOpToOuterProductOpLowering"
** Insert : 'vector.transpose'(0x5625b3a8cb30)
** Insert : 'vector.transpose'(0x5625b3a8cbc0)
"(anonymous namespace)::ContractionOpToOuterProductOpLowering" result 0
} -> failure : pattern failed to match
} -> failure : pattern failed to match
LLVM ERROR: pattern returned failure but IR did change
```
Note: `vector-contract-to-outerproduct-transforms-unsupported.mlir` is
merged into `vector-contract-to-outerproduct-matvec-transforms.mlir`.
The `greedy pattern application failed` error is not longer produced.
This error indicates that the greedy pattern rewrite did not
convergence; it does not mean that a pattern could not be applied.
More information about the All-commits
mailing list