Add support for some multi-store cases in affine fusion
authorDiego Caballero <diego.caballero@intel.com>
Wed, 9 Oct 2019 17:36:54 +0000 (10:36 -0700)
committerA. Unique TensorFlower <gardener@tensorflow.org>
Wed, 9 Oct 2019 17:37:30 +0000 (10:37 -0700)
commit3451055614a26f353438430d32e7920ce57ab4b9
tree3943c2f2df1b15c9d886546b1ecfb778b466fb6f
parent15f8ee62239c61300b03f07d49cadb1b0a990fd4
Add support for some multi-store cases in affine fusion

This PR is a stepping stone towards supporting generic multi-store
source loop nests in affine loop fusion. It extends the algorithm to
support fusion of multi-store loop nests that:
 1. have only one store that writes to a function-local live out, and
 2. the remaining stores are involved in loop nest self dependences
    or no dependences within the function.

Closes tensorflow/mlir#162

COPYBARA_INTEGRATE_REVIEW=https://github.com/tensorflow/mlir/pull/162 from dcaballe:dcaballe/multi-output-fusion 7fb7dec6fe8b45f5ce176f018bfe37b256420c45
PiperOrigin-RevId: 273773907
mlir/lib/Transforms/LoopFusion.cpp
mlir/test/Transforms/loop-fusion.mlir