[llvm] Users/xiangzhangllvm/loop unroll folding branches (PR #74703)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Fri Dec 8 01:19:09 PST 2023
================
@@ -776,6 +776,11 @@ shouldPragmaUnroll(Loop *L, const PragmaInfo &PInfo,
if (PInfo.PragmaFullUnroll && TripCount != 0)
return TripCount;
+ // Small MaxTripCount is clearly calculated with "pragma unroll".
----------------
nikic wrote:
Ah, I get what you mean now. It would probably be okay to use a higher limit than UnrollMaxUpperBound if pragma is involved, but I agree that simply unrolling to any MaxTripCount would not be safe.
https://github.com/llvm/llvm-project/pull/74703
More information about the llvm-commits
mailing list