summaryrefslogtreecommitdiffstats
path: root/polly/test/Isl/CodeGen/OpenMP/single_loop.ll
diff options
context:
space:
mode:
authorHongbin Zheng <etherzhhb@gmail.com>2017-05-12 02:17:15 +0000
committerHongbin Zheng <etherzhhb@gmail.com>2017-05-12 02:17:15 +0000
commit4fe342cb7560993988dd6f978607a2442a905910 (patch)
tree8bf533c3b47257ff876e06caa6f0d2469568fef2 /polly/test/Isl/CodeGen/OpenMP/single_loop.ll
parent581072e1a6591d65e55b21d6dce2459a3dffe81a (diff)
downloadbcm5719-llvm-4fe342cb7560993988dd6f978607a2442a905910.tar.gz
bcm5719-llvm-4fe342cb7560993988dd6f978607a2442a905910.zip
[Polly] Generate more 'canonical' induction variable
Today Polly generates induction variable in this way: polly.indvar = phi 0, polly.indvar.next ... polly.indvar.next = polly.indvar + stide polly.loop_cond = predicate polly.indvar, (UB - stride) Instead of: polly.indvar = phi 0, polly.indvar.next ... polly.indvar.next = polly.indvar + stide polly.loop_cond = predicate polly.indvar.next, UB The way Polly generate induction variable cause some problem in the indvar simplify pass. This patch make polly generate the later form, by assuming the induction variable never overflow Differential Revision: https://reviews.llvm.org/D33089 llvm-svn: 302866
Diffstat (limited to 'polly/test/Isl/CodeGen/OpenMP/single_loop.ll')
-rw-r--r--polly/test/Isl/CodeGen/OpenMP/single_loop.ll3
1 files changed, 1 insertions, 2 deletions
diff --git a/polly/test/Isl/CodeGen/OpenMP/single_loop.ll b/polly/test/Isl/CodeGen/OpenMP/single_loop.ll
index eced8ea3a09..f258410d053 100644
--- a/polly/test/Isl/CodeGen/OpenMP/single_loop.ll
+++ b/polly/test/Isl/CodeGen/OpenMP/single_loop.ll
@@ -70,8 +70,7 @@
; IR-NEXT: %[[gep:[._a-zA-Z0-9]*]] = getelementptr [1024 x float], [1024 x float]* {{.*}}, i64 0, i64 %polly.indvar
; IR-NEXT: store float 1.000000e+00, float* %[[gep]]
; IR-NEXT: %polly.indvar_next = add nsw i64 %polly.indvar, 1
-; IR-NEXT: %polly.adjust_ub = sub i64 %polly.par.UBAdjusted, 1
-; IR-NEXT: %polly.loop_cond = icmp sle i64 %polly.indvar, %polly.adjust_ub
+; IR-NEXT: %polly.loop_cond = icmp sle i64 %polly.indvar_next, %polly.par.UBAdjusted
; IR-NEXT: br i1 %polly.loop_cond, label %polly.loop_header, label %polly.loop_exit
; IR-LABEL: polly.loop_preheader:
OpenPOWER on IntegriCloud