[all-commits] [llvm/llvm-project] e86def: [mlir][tosa] Add type checking traits to the appro...
TatWai Chong via All-commits
all-commits at lists.llvm.org
Thu May 25 17:03:32 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: e86defd588e79de60d19a101a43b0c8c86dff37b
https://github.com/llvm/llvm-project/commit/e86defd588e79de60d19a101a43b0c8c86dff37b
Author: TatWai Chong <tatwai.chong at arm.com>
Date: 2023-05-25 (Thu, 25 May 2023)
Changed paths:
M mlir/include/mlir/Dialect/Tosa/IR/TosaOpBase.td
M mlir/include/mlir/Dialect/Tosa/IR/TosaOps.td
M mlir/test/Conversion/TosaToLinalg/tosa-to-linalg.mlir
Log Message:
-----------
[mlir][tosa] Add type checking traits to the appropriate ops
Add the trait `SameOperandsAndResultElementType` and
`SameOperandsElementType` to verify ops that are known
to have the same input and output type rather than generate
an invalid tosa IR with mixed data types like:
"tosa.add"(%0, %1) : (tensor<nxbf16>, tensor<nxf32>) -> tensor<nxf32>
Thus apply tosa.cast prior if needed.
Change-Id: Ie866b84e371e3b571ec04f7abb090c216dd39c33
Reviewed By: jpienaar
Differential Revision: https://reviews.llvm.org/D150472
More information about the All-commits
mailing list