[all-commits] [llvm/llvm-project] 67ef4a: [MLIR][Tensor, MemRef] Fold expand_shape and collap...
James Newling via All-commits
all-commits at lists.llvm.org
Mon Mar 11 18:12:19 PDT 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 67ef4ae2c3cc4e2700e873aa6f251b70a09c3fea
https://github.com/llvm/llvm-project/commit/67ef4ae2c3cc4e2700e873aa6f251b70a09c3fea
Author: James Newling <james.newling at gmail.com>
Date: 2024-03-12 (Tue, 12 Mar 2024)
Changed paths:
M mlir/include/mlir/Dialect/MemRef/IR/MemRefOps.td
M mlir/include/mlir/Dialect/Tensor/IR/TensorOps.td
M mlir/include/mlir/Dialect/Utils/ReshapeOpsUtils.h
M mlir/lib/Dialect/MemRef/IR/MemRefOps.cpp
M mlir/lib/Dialect/Tensor/IR/TensorOps.cpp
M mlir/test/Dialect/MemRef/canonicalize.mlir
M mlir/test/Dialect/MemRef/invalid.mlir
M mlir/test/Dialect/Tensor/canonicalize.mlir
M mlir/test/Dialect/Tensor/invalid.mlir
Log Message:
-----------
[MLIR][Tensor,MemRef] Fold expand_shape and collapse_shape if identity (#80658)
Before: op verifiers failed if the input and output ranks were the same
(i.e. no expansion or collapse). This behavior requires users of these
shape ops to verify manually that they are not creating identity
versions of these ops every time they build them -- problematic. This PR
removes this strict verification, and introduces folders for the the
identity cases.
The PR also removes the special case handling of rank-0 tensors for
expand_shape and collapse_shape, there doesn't seem to be any reason to
treat them differently.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list