[PATCH] D46162: [PowerPC] Don't transform to CTR loop if the decrement branch instr. would end up in a different loop

Nemanja Ivanovic via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed May 2 04:15:29 PDT 2018


nemanjai updated this revision to Diff 144848.
nemanjai added a comment.

Added a check for irreducible CFG within the loop being considered for transformation - thanks for the pointers @efriedma and @hfinkel.
We simply bail out of the transformation if the loop has irreducible control flow rather than analyzing said control flow. This results in a total reduction of 2 loops out of 25,432 that are transformed in a bootstrap build.


Repository:
  rL LLVM

https://reviews.llvm.org/D46162

Files:
  lib/Target/PowerPC/PPCCTRLoops.cpp
  test/CodeGen/PowerPC/no-ctr-loop-if-exit-in-nested-loop.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D46162.144848.patch
Type: text/x-patch
Size: 4398 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180502/3d89a9a2/attachment.bin>


More information about the llvm-commits mailing list