[PATCH] D73944: [mlir][wip] Start Shape dialect
Stella Laurenzo via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Feb 8 15:50:42 PST 2020
stellaraccident added inline comments.
================
Comment at: mlir/include/mlir/Dialect/Shape/IR/ShapeOps.td:190
+
+ output[i] = lhs[i] if lhs[i] == rhs[i] or rhs[i] is unknown/undefined
+ = rhs[i] if lhs[i] is unknown/undefined
----------------
nicolasvasilache wrote:
> nicolasvasilache wrote:
> > This is frontend logic that I do not think should leak into MLIR.
> I meant into MLIR *core*, sorry.
I tend to agree. We do need this to lower frontend dialects that choose to implement numpy-style broadcasting, but that does not mean it needs to be in core (or at least in this level of core -- I could see having a numpy_broadcast_shape op somewhere).
I suspect that there may have been some thought of needing this in some follow-on analysis algorithms. It would probably be better to discuss more in that context.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D73944/new/
https://reviews.llvm.org/D73944
More information about the llvm-commits
mailing list