[all-commits] [llvm/llvm-project] 5fee17: [mlir] translate memref.reshape with static shapes...
Ashay Rane via All-commits
all-commits at lists.llvm.org
Thu Jun 2 10:01:12 PDT 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 5fee1799f4d8da59c251e2d04172fc2f387cbe54
https://github.com/llvm/llvm-project/commit/5fee1799f4d8da59c251e2d04172fc2f387cbe54
Author: Ashay Rane <ashay at users.noreply.github.com>
Date: 2022-06-02 (Thu, 02 Jun 2022)
Changed paths:
M mlir/lib/Conversion/MemRefToLLVM/MemRefToLLVM.cpp
M mlir/test/Conversion/MemRefToLLVM/convert-static-memref-ops.mlir
Log Message:
-----------
[mlir] translate memref.reshape with static shapes but dynamic dims
Prior to this patch, the lowering of memref.reshape operations to the
LLVM dialect failed if the shape argument had a static shape with
dynamic dimensions. This patch adds the necessary support so that when
the shape argument has dynamic values, the lowering probes the dimension
at runtime to set the size in the `MemRefDescriptor` type. This patch
also computes the stride for dynamic dimensions by deriving it from the
sizes of the inner dimensions.
Reviewed By: ftynse
Differential Revision: https://reviews.llvm.org/D126604
More information about the All-commits
mailing list