llvm-project/llvm/test/Transforms/LoopFusion
Kit Barton 3cdf87940f Add basic loop fusion pass.
This patch adds a basic loop fusion pass. It will fuse loops that conform to the
following 4 conditions:
  1. Adjacent (no code between them)
  2. Control flow equivalent (if one loop executes, the other loop executes)
  3. Identical bounds (both loops iterate the same number of iterations)
  4. No negative distance dependencies between the loop bodies.

The pass does not make any changes to the IR to create opportunities for fusion.
Instead, it checks if the necessary conditions are met and if so it fuses two
loops together.

The pass has not been added to the pass pipeline yet, and thus is not enabled by
default. It can be run stand alone using the -loop-fusion option.

Differential Revision: https://reviews.llvm.org/D55851

llvm-svn: 358607
2019-04-17 18:53:27 +00:00
..
cannot_fuse.ll Add basic loop fusion pass. 2019-04-17 18:53:27 +00:00
four_loops.ll Add basic loop fusion pass. 2019-04-17 18:53:27 +00:00
inner_loops.ll Add basic loop fusion pass. 2019-04-17 18:53:27 +00:00
loop_nest.ll Add basic loop fusion pass. 2019-04-17 18:53:27 +00:00
simple.ll Add basic loop fusion pass. 2019-04-17 18:53:27 +00:00