[mlir][Linalg] Introduce canonicalization to remove dead LinalgOps
When any of the memrefs in a structured linalg op has a zero dimension, it becomes dead. This is consistent with the fact that linalg ops deduce their loop bounds from their operands. Note however that this is not the case for the `tensor<0xelt_type>` which is a special convention that must be lowered away into either `memref<elt_type>` or just `elt_type` before this canonicalization can kick in. Differential Revision: https://reviews.llvm.org/D85413
Loading
Please sign in to comment