Commit b21949e
authored
Revert "[mlir][memref]: Collapse strided unit dim even if strides are dynamic" (llvm#166448)
Reverts llvm#157330
The original revision introduces a bug in `isGuaranteedCollapsible`. The
`memref<3x3x1x96xf32, strided<[288, 96, 96, 1], offset: 864>>` is no
longer collapsable with the change. The revision reverts the change to
bring back correct behavior. `stride` should be computed as `96` like
the old behavior in the failed iteration.
https://github.com/llvm/llvm-project/blob/92a1eb37122fa24e3045fbabdea2bf87127cace5/mlir/lib/Dialect/MemRef/IR/MemRefOps.cpp#L2597-L26051 parent 025e431 commit b21949e
File tree
2 files changed
+6
-11
lines changed- mlir
- lib/Dialect/MemRef/IR
- test/Dialect/MemRef
2 files changed
+6
-11
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2568 | 2568 | | |
2569 | 2569 | | |
2570 | 2570 | | |
2571 | | - | |
2572 | | - | |
2573 | | - | |
2574 | | - | |
2575 | | - | |
2576 | 2571 | | |
2577 | 2572 | | |
2578 | 2573 | | |
| |||
2587 | 2582 | | |
2588 | 2583 | | |
2589 | 2584 | | |
| 2585 | + | |
| 2586 | + | |
| 2587 | + | |
| 2588 | + | |
| 2589 | + | |
2590 | 2590 | | |
2591 | 2591 | | |
2592 | 2592 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
440 | 440 | | |
441 | 441 | | |
442 | 442 | | |
443 | | - | |
444 | | - | |
| 443 | + | |
445 | 444 | | |
446 | 445 | | |
447 | 446 | | |
| |||
490 | 489 | | |
491 | 490 | | |
492 | 491 | | |
493 | | - | |
494 | | - | |
495 | | - | |
496 | | - | |
497 | 492 | | |
498 | 493 | | |
499 | 494 | | |
| |||
0 commit comments