[PATCH] D38952: [ARM] Allow unrolling on multi-block loops.

Eli Friedman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 16 12:06:56 PDT 2017


efriedma added inline comments.


================
Comment at: lib/Target/ARM/ARMTargetTransformInfo.cpp:606
+
+  if (ExitingBlocks.size() > 2)
+    return;
----------------
The magic numbers "2" and "4" need comments explaining them.


================
Comment at: lib/Target/ARM/ARMTargetTransformInfo.cpp:628
+                                            I.value_op_end());
+      Cost += getUserCost(&I, Operands);
     }
----------------
Would it make sense to break out of this loop early if "Cost" is 12 or more?


https://reviews.llvm.org/D38952





More information about the llvm-commits mailing list