[PATCH] D71025: [LoopFusion] Restrict loop fusion to rotated loops.

Kit Barton via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 16 09:02:16 PST 2019


kbarton marked 4 inline comments as done.
kbarton added a comment.

Addressed all the review comments. 
I'm ready to land this, unless @Whitney has concerns about the test case.



================
Comment at: llvm/test/Transforms/LoopFusion/cannot_fuse.ll:42
+bb34:
+  %cmp = icmp slt i32 %N, 50
+  br i1 %cmp, label %bb16, label %bb33
----------------
Whitney wrote:
> This guard was not in the original test case, now the second loop has two guards, is that intensional?                    
Yes, this is intentional to make the two loops not control-flow-equivalent, which is what this specific test is checking. 


================
Comment at: llvm/test/Transforms/LoopFusion/cannot_fuse.ll:270
 ; CHECK-NEXT: [[LOOP2PREHEADER]]
-; CHECK: Memory dependencies do not allow fusion!
+; CHECK: Fusion candidate does not have empty preheader. Not fusing.
 ; CHECK: Loop Fusion complete
----------------
Meinersbur wrote:
> Does this test something different now?
This is a good catch. I missed this. I've fixed it to check for the memory dependencies again. 


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D71025





More information about the llvm-commits mailing list