[MLIR] Add memref dialect dependency for affine fusion pass
authorVinayaka Bandishti <vinayaka@polymagelabs.com>
Sat, 8 May 2021 14:42:23 +0000 (20:12 +0530)
committerUday Bondhugula <uday@polymagelabs.com>
Sat, 8 May 2021 14:42:33 +0000 (20:12 +0530)
commit9610a2d753dbba385e8c2c005e2497e3add99472
treeb3a13f2e97e2cd0651ca7ec794c5f4f7a7e53c77
parent73df48158bf5460b5e3497ccec0df4c62c570fad
[MLIR] Add memref dialect dependency for affine fusion pass

For `AffineLoopFusion` pass, add `memref` dialect as a dependent
dialect. Since the fusion pass can create `memref::AllocOp`s, the
dialect must be registered in its dependent dialects.

The missing dependency was not discovered until now because the above
said op creation happes only when the input already has
`memref::AllocOp`s in it, and all dialects in the input are
automatically added to the context.

Reviewed By: bondhugula

Differential Revision: https://reviews.llvm.org/D102104
mlir/include/mlir/Transforms/Passes.td