[PATCH] D104659: [ARM] Limit v6m unrolling with multiple live outs

Dave Green via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 22 06:37:48 PDT 2021


dmgreen added inline comments.


================
Comment at: llvm/lib/Target/ARM/ARMTargetTransformInfo.cpp:2209
+      });
+      ExitingValues = ExitingValues < LiveOuts ? LiveOuts : ExitingValues;
+    }
----------------
SjoerdMeijer wrote:
> I was wondering if this is right. I.e., we are not e.g. accumulating the exit values, or taking a maximum, or something like that, if I am not mistaken. 
I would expect that most loops have a single exit, but the code above does allow (at most) 2 exit.

>From those I took the maximum of the number of liveouts as a rough heuristic, as I would expect the liveouts to be the same in many cases for multi-exit loops, and it probably doesn't want to count them twice.


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

https://reviews.llvm.org/D104659



More information about the llvm-commits mailing list