[polly] r246483 - Fix another typo in the subloop counting
Tobias Grosser via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 31 14:04:52 PDT 2015
Author: grosser
Date: Mon Aug 31 16:04:51 2015
New Revision: 246483
URL: http://llvm.org/viewvc/llvm-project?rev=246483&view=rev
Log:
Fix another typo in the subloop counting
... as well as the corresponding test cases.
Thank's Johannes for finding this bug.
Modified:
polly/trunk/lib/Analysis/ScopDetection.cpp
polly/trunk/test/ScopDetect/more-than-one-loop.ll
Modified: polly/trunk/lib/Analysis/ScopDetection.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/Analysis/ScopDetection.cpp?rev=246483&r1=246482&r2=246483&view=diff
==============================================================================
--- polly/trunk/lib/Analysis/ScopDetection.cpp (original)
+++ polly/trunk/lib/Analysis/ScopDetection.cpp Mon Aug 31 16:04:51 2015
@@ -791,7 +791,7 @@ bool ScopDetection::hasMoreThanOneLoop(R
for (auto &SubLoop : SubLoops)
if (R->contains(SubLoop)) {
LoopNum++;
- if (SubLoop > 0)
+ if (SubLoop->getSubLoopsVector().size() > 0)
LoopNum++;
if (LoopNum >= 2)
Modified: polly/trunk/test/ScopDetect/more-than-one-loop.ll
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/test/ScopDetect/more-than-one-loop.ll?rev=246483&r1=246482&r2=246483&view=diff
==============================================================================
--- polly/trunk/test/ScopDetect/more-than-one-loop.ll (original)
+++ polly/trunk/test/ScopDetect/more-than-one-loop.ll Mon Aug 31 16:04:51 2015
@@ -20,6 +20,9 @@
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
define void @foo(float* %A, float* %B, i64 %N) {
+entry:
+ br label %bb
+
bb:
%tmp = icmp sgt i64 %N, 100
br i1 %tmp, label %bb2, label %bb12
More information about the llvm-commits
mailing list