[PATCH] D73641: [LoopFusion] Move instructions from FC1.GuardBlock to FC0.GuardBlock and from FC0.ExitBlock to FC1.ExitBlock when proven safe.

Johannes Doerfert via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 29 12:17:06 PST 2020


jdoerfert added inline comments.


================
Comment at: llvm/lib/Transforms/Scalar/LoopFuse.cpp:766
 
-          if (FC1->GuardBranch && !isEmptyGuardBlock(*FC1)) {
-            LLVM_DEBUG(dbgs() << "Fusion candidate does not have empty guard "
----------------
Do we still need these `isEmptyXXXBlock` methods?


================
Comment at: llvm/lib/Transforms/Scalar/LoopFuse.cpp:776
             continue;
           }
 
----------------
What happens now if there is a FC1 guard branch with non-movable instructions but no fc0 guard branch. I think we now miss that case and do sth? Could you add a test if we don't have one?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D73641





More information about the llvm-commits mailing list