1 ; RUN: opt %loadPolly -polly-print-scops -disable-output < %s | FileCheck %s
3 ; CHECK: Assumed Context:
4 ; CHECK-NEXT: [N] -> { : }
5 ; CHECK-NEXT: Invalid Context:
6 ; CHECK-NEXT: [N] -> { : N >= 4294967297 }
9 ; CHECK-NEXT: Stmt_for_body
10 ; CHECK-NEXT: Domain :=
11 ; CHECK-NEXT: [N] -> { Stmt_for_body[i0] : 0 <= i0 < N };
12 ; CHECK-NEXT: Schedule :=
13 ; CHECK-NEXT: [N] -> { Stmt_for_body[i0] -> [i0] };
14 ; CHECK-NEXT: ReadAccess := [Reduction Type: +] [Scalar: 0]
15 ; CHECK-NEXT: [N] -> { Stmt_for_body[i0] -> MemRef_A[i0] };
16 ; CHECK-NEXT: MustWriteAccess := [Reduction Type: +] [Scalar: 0]
17 ; CHECK-NEXT: [N] -> { Stmt_for_body[i0] -> MemRef_A[i0] };
20 ; void f(long *A, long N) {
21 ; long K = /* 2^32 */ 4294967296;
22 ; for (long i = 0; i < N; i++) {
27 target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
29 define void @f(ptr %A, i64 %N) {
33 for.cond: ; preds = %for.inc, %entry
34 %i.0 = phi i64 [ 0, %entry ], [ %inc1, %for.inc ]
35 %cmp = icmp slt i64 %i.0, %N
36 br i1 %cmp, label %for.body, label %for.end
38 for.body: ; preds = %for.cond
39 %i.t = trunc i64 %i.0 to i33
40 %rem = zext i33 %i.t to i64
41 %arrayidx = getelementptr inbounds i64, ptr %A, i64 %rem
42 %tmp = load i64, ptr %arrayidx, align 4
43 %inc = add nsw i64 %tmp, 1
44 store i64 %inc, ptr %arrayidx, align 4
47 for.inc: ; preds = %for.body
48 %inc1 = add nuw nsw i64 %i.0, 1
51 for.end: ; preds = %for.cond