When this interface is used, a call to inferReturnTypeComponents()
is generated on creation and verification of the op.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
mlir/test/Dialect/Tosa/invalid.mlir | ||
---|---|---|
102 ↗ | (On Diff #510396) | I would remove the function name check and the newlines, to align to the other tests. |
mlir/lib/Dialect/Tosa/IR/TosaOps.cpp | ||
---|---|---|
944 | Can we have a static method with this implementation? Then it can be called here and in tosa::ConcatOp::isCompatibleReturnTypes to avoid code duplication. |
mlir/lib/Dialect/Tosa/IR/TosaOps.cpp | ||
---|---|---|
933 | The tosa operations that have this macro are not changing the tensor length/element type, and all of them working on tensors with length 1. Actually lhs and rhs must be from the same length from the first condition (otherwise we will return false). From the second condition lhs mustn't be 1. From the combination of those conditions we can deduce that we will return false also if rhs is 1 also (either lhs is 1 also nor rhs != lhs). | |
944 | Ack. thanks. |
So rhs size being 1 would be an error but if lhs were 1 then it's fine? (For example, if r.size() was 0 then the below would assert)