Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
mlir/lib/Dialect/Tosa/IR/TosaOps.cpp | ||
---|---|---|
970 | Done, and I moved up the resolveBroadcastShape function so that EqualOp::inferReturnTypeComponents can use it |
mlir/lib/Dialect/Tosa/IR/TosaOps.cpp | ||
---|---|---|
346 | This function is returning failure for case where operands are invalid as well as in this case where we can't produce anything other than unranked. That's not ideal. Could you add a TODO that this should be updated? | |
466 | Lets return success here and then we can flatten else. | |
468 | Instead of creating and mutating in place, I think we can just construct. | |
470 | Above you are calculating the broadcasted shape but here you just take first operand which could not match the broadcasted shape (e.g., scalar first operand). |
mlir/lib/Dialect/Tosa/IR/TosaOps.cpp | ||
---|---|---|
471 |
Should I be using the result type here instead of the first operand's type? |
mlir/lib/Dialect/Tosa/IR/TosaOps.cpp | ||
---|---|---|
471 | Use the shape you computed above in resolveBroadcastShape yes. |
LG and we can refine post the above TODO.
mlir/lib/Dialect/Tosa/IR/TosaOps.cpp | ||
---|---|---|
475 | Do we get here? |
mlir/lib/Dialect/Tosa/IR/TosaOps.cpp | ||
---|---|---|
475 | Ah that case wouldn't be reached because resolveBroadcastShape already checks that all the tensors have rank |
This function is returning failure for case where operands are invalid as well as in this case where we can't produce anything other than unranked. That's not ideal. Could you add a TODO that this should be updated?