This revision introduces proper backward slice computation during the hoisting of
PadTensorOp. This allows hoisting padding even across multiple levels of tiling.
Such hoisting requires the proper handling of loop bounds that may depend on enclosing
loop variables.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
mlir/lib/Dialect/Linalg/Transforms/Hoisting.cpp | ||
---|---|---|
512 | s/upper/lower | |
549–550 | This feels like it can lead to invalid IR being produced. Just skipping over an op with regions that produces value will fail to create new values for these ops, and the old values will be used before being defined. I suppose we want to bail out completely. In this case, we also don't want to create ops spuriously, so I would suggest factoring out the validity check (no regions + no side effects) into a separate block/function that runs before we start creating new ops. | |
552–554 | I suppose we shouldn't blindly clone side-effecting ops. | |
mlir/test/Dialect/Linalg/hoist-padding.mlir | ||
3 | Nit: passing -mlir-print-local-scope will print this inline and make tests more self-contained |
s/upper/lower