summaryrefslogtreecommitdiffstats
path: root/llvm/test/Transforms/LoopInterchange/interchange-not-profitable.ll
diff options
context:
space:
mode:
authorFlorian Hahn <florian.hahn@arm.com>2018-04-03 16:37:58 +0000
committerFlorian Hahn <florian.hahn@arm.com>2018-04-03 16:37:58 +0000
commitb79217077dfbad6c255282dd3b8f134a2876d5a0 (patch)
tree45275e54d0ee222294d832e9cac260e01a5ede0b /llvm/test/Transforms/LoopInterchange/interchange-not-profitable.ll
parent976aff148adf3008cbfd3190532353db25877378 (diff)
downloadbcm5719-llvm-b79217077dfbad6c255282dd3b8f134a2876d5a0.tar.gz
bcm5719-llvm-b79217077dfbad6c255282dd3b8f134a2876d5a0.zip
[LoopInterchange] Update tests so DA can handle access after D35430.
I have taken the opportunity to simplify some tests slightly and move parts around. It also brings back a few IR checks for interchangable loops. Reviewers: karthikthecool, sebpop, grosser Reviewed By: sebpop Differential Revision: https://reviews.llvm.org/D45207 llvm-svn: 329081
Diffstat (limited to 'llvm/test/Transforms/LoopInterchange/interchange-not-profitable.ll')
-rw-r--r--llvm/test/Transforms/LoopInterchange/interchange-not-profitable.ll42
1 files changed, 0 insertions, 42 deletions
diff --git a/llvm/test/Transforms/LoopInterchange/interchange-not-profitable.ll b/llvm/test/Transforms/LoopInterchange/interchange-not-profitable.ll
deleted file mode 100644
index f0d21c6f5a5..00000000000
--- a/llvm/test/Transforms/LoopInterchange/interchange-not-profitable.ll
+++ /dev/null
@@ -1,42 +0,0 @@
-; REQUIRES: asserts
-; RUN: opt < %s -basicaa -loop-interchange -S -debug 2>&1 | FileCheck %s
-
-target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
-target triple = "x86_64-unknown-linux-gnu"
-
-@A = common global [100 x [100 x i32]] zeroinitializer
-@B = common global [100 x i32] zeroinitializer
-
-;; Loops should not be interchanged in this case as it is not profitable.
-;; for(int i=0;i<100;i++)
-;; for(int j=0;j<100;j++)
-;; A[i][j] = A[i][j]+k;
-
-; CHECK: Interchanging loops not profitable.
-
-define void @interchange_03(i32 %k) {
-entry:
- br label %for.cond1.preheader
-
-for.cond1.preheader:
- %indvars.iv21 = phi i64 [ 0, %entry ], [ %indvars.iv.next22, %for.inc10 ]
- br label %for.body3
-
-for.body3:
- %indvars.iv = phi i64 [ 0, %for.cond1.preheader ], [ %indvars.iv.next, %for.body3 ]
- %arrayidx5 = getelementptr inbounds [100 x [100 x i32]], [100 x [100 x i32]]* @A, i64 0, i64 %indvars.iv21, i64 %indvars.iv
- %0 = load i32, i32* %arrayidx5
- %add = add nsw i32 %0, %k
- store i32 %add, i32* %arrayidx5
- %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
- %exitcond = icmp eq i64 %indvars.iv.next, 100
- br i1 %exitcond, label %for.inc10, label %for.body3
-
-for.inc10:
- %indvars.iv.next22 = add nuw nsw i64 %indvars.iv21, 1
- %exitcond23 = icmp eq i64 %indvars.iv.next22, 100
- br i1 %exitcond23, label %for.end12, label %for.cond1.preheader
-
-for.end12:
- ret void
-}
OpenPOWER on IntegriCloud