diff options
author | Eric Christopher <echristo@gmail.com> | 2016-03-15 02:19:06 +0000 |
---|---|---|
committer | Eric Christopher <echristo@gmail.com> | 2016-03-15 02:19:06 +0000 |
commit | ee00abe5e66be17f601475e4397447f347287f6a (patch) | |
tree | 5eb9e8724c3810016e0198911f702630e4ef5ab8 /llvm/lib/Transforms/Utils/LoopUnroll.cpp | |
parent | b43027d1e0ebc57f6efb8961f3eb4df1b0828ba1 (diff) | |
download | llvm-ee00abe5e66be17f601475e4397447f347287f6a.zip llvm-ee00abe5e66be17f601475e4397447f347287f6a.tar.gz llvm-ee00abe5e66be17f601475e4397447f347287f6a.tar.bz2 |
Fix llvm/llvm/lib/Transforms/Utils/LoopUnroll.cpp:285:53: error: suggest
parentheses around '&&' within '||' [-Werror=parentheses].
llvm-svn: 263525
Diffstat (limited to 'llvm/lib/Transforms/Utils/LoopUnroll.cpp')
-rw-r--r-- | llvm/lib/Transforms/Utils/LoopUnroll.cpp | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/llvm/lib/Transforms/Utils/LoopUnroll.cpp b/llvm/lib/Transforms/Utils/LoopUnroll.cpp index fb98b30..505e452 100644 --- a/llvm/lib/Transforms/Utils/LoopUnroll.cpp +++ b/llvm/lib/Transforms/Utils/LoopUnroll.cpp @@ -275,17 +275,15 @@ bool llvm::UnrollLoop(Loop *L, unsigned Count, unsigned TripCount, // Loops containing convergent instructions must have a count that divides // their TripMultiple. - DEBUG( - bool HasConvergent = false; - for (auto &BB : L->blocks()) - for (auto &I : *BB) - if (auto CS = CallSite(&I)) - HasConvergent |= CS.isConvergent(); - assert( - !HasConvergent || TripMultiple % Count == 0 && - "Unroll count must divide trip multiple if loop contains a convergent " - "operation."); - ); + DEBUG(bool HasConvergent = false; + for (auto &BB + : L->blocks()) for (auto &I + : *BB) if (auto CS = CallSite(&I)) + HasConvergent |= CS.isConvergent(); + assert((!HasConvergent || TripMultiple % Count == 0) && + "Unroll count must divide trip multiple if loop contains a " + "convergent " + "operation.");); // Don't output the runtime loop prolog if Count is a multiple of // TripMultiple. Such a prolog is never needed, and is unsafe if the loop // contains a convergent instruction. |