[PATCH] D11706: [Unroll] Improve the brute force loop unroll estimate by propagating through PHI nodes across iterations.

Michael Zolotukhin mzolotukhin at apple.com
Mon Aug 3 14:53:43 PDT 2015


mzolotukhin added a comment.

Thanks!


================
Comment at: lib/Transforms/Scalar/LoopUnrollPass.cpp:551-553
@@ +550,5 @@
+  // this analysis.
+  assert(L->isLoopSimplifyForm() && "Must put loop into normal form first.");
+  assert(L->isLCSSAForm(DT) &&
+         "Must have loops in LCSSA form to track live-out values.");
+
----------------
chandlerc wrote:
> mzolotukhin wrote:
> > Shouldn't we just bail out in this case instead of crashing with assert?
> > IOW, is it possible to make a loop, that won't be simplified, but will reach this point?
> My intent is for that to be the responsibility of the caller.
> 
> In this case, a LoopPass operates under these specific invariants. This is why we require and preserve LoopSimplify and LCSSA above.
> 
> So currently, no, it isn't possible without a bug somewhere.
Sounds good, just wanted to verify this.


Repository:
  rL LLVM

http://reviews.llvm.org/D11706







More information about the llvm-commits mailing list