add missing memref cast fold pattern for dim op
authorUday Bondhugula <udayb@iisc.ac.in>
Sat, 14 Sep 2019 01:18:21 +0000 (18:18 -0700)
committerA. Unique TensorFlower <gardener@tensorflow.org>
Sat, 14 Sep 2019 01:18:48 +0000 (18:18 -0700)
commit1e6a93b7cae61c777ec4ce06a5f6d7d2b81af0ea
tree912439020966641e075f4318960ca1f493f07365
parentd780bdef2050f6485396e73220ec76455c563c17
add missing memref cast fold pattern for dim op

- add missing canonicalization pattern to fold memref_cast + dim to
  dim (needed to propagate constant when folding a dynamic shape to
  a static one)

- also fix an outdated/inconsistent comment in StandardOps/Ops.td

Signed-off-by: Uday Bondhugula <uday@polymagelabs.com>
Closes tensorflow/mlir#126

COPYBARA_INTEGRATE_REVIEW=https://github.com/tensorflow/mlir/pull/126 from bondhugula:quickfix 4566e75e49685c532faffff91d64c5d83d4da524
PiperOrigin-RevId: 269020058
mlir/include/mlir/Dialect/StandardOps/Ops.td
mlir/lib/Dialect/StandardOps/Ops.cpp
mlir/test/Transforms/canonicalize.mlir