[PATCH] D136483: [mlir][MemRefToLLVM] Reuse existing lowering for collaspe/expand_shape

Quentin Colombet via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 26 21:40:45 PDT 2022


qcolombet added a comment.

Oh and I forgot.
Another reason for having more IR is because we kept each affine expression independent to each other and some terms may be repeated between two expressions.
E.g.,

  newSize = oldSize1 * oldSize2
  finalOffset = oldOffset * oldSize1 * oldSize2

Here `oldSize1 * oldSize2` could be reused (or CSE'd) but is currently expanded twice (once for each `affine.apply` expression.)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D136483/new/

https://reviews.llvm.org/D136483



More information about the llvm-commits mailing list