[PATCH] D18898: [Loop Rotation] Make default max rotation header size threshold dependent on target CPU

Eric Christopher via llvm-commits llvm-commits at lists.llvm.org
Sun May 1 21:57:32 PDT 2016


echristo added inline comments.

================
Comment at: lib/Target/X86/X86TargetTransformInfo.cpp:1490
@@ +1489,3 @@
+
+unsigned X86TTIImpl::getLoopRotationDefaultThreshold() const {
+  return ST->getCPU() == "lakemont" ? 2 : 16;
----------------
Explain the change?

================
Comment at: lib/Transforms/Scalar/LoopRotation.cpp:580
@@ -567,3 +579,3 @@
 class LoopRotate : public LoopPass {
-  unsigned MaxHeaderSize;
+  Optional<unsigned> SpecifiedThreshold;
 
----------------
This all feels awkward. Can you try to rework this a bit?


http://reviews.llvm.org/D18898





More information about the llvm-commits mailing list