1 ; RUN: opt %loadPolly -polly-scops -analyze < %s | FileCheck %s
3 ; void f(int a[], int N, float *P) {
5 ; for (i = 0; i < N; ++i)
10 target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128"
12 define void @f(i64* nocapture %a, i64 %N, float * %P) nounwind {
17 %i = phi i64 [ 0, %entry ], [ %i.inc, %bb.backedge ]
18 %brcond = icmp ne float* %P, null
19 br i1 %brcond, label %store, label %bb.backedge
22 %scevgep = getelementptr inbounds i64, i64* %a, i64 %i
23 store i64 %i, i64* %scevgep
27 %i.inc = add nsw i64 %i, 1
28 %exitcond = icmp eq i64 %i.inc, %N
29 br i1 %exitcond, label %return, label %bb
35 ; CHECK: Assumed Context:
37 ; CHECK-NEXT: Invalid Context:
38 ; CHECK-NEXT: { : 1 = 0 }
42 ; CHECK: [P, N] -> { Stmt_store[i0] : 0 <= i0 < N and (P < 0 or P > 0) };
44 ; CHECK: [P, N] -> { Stmt_store[i0] -> [i0] : P < 0 or P > 0 };
45 ; CHECK: MustWriteAccess := [Reduction Type: NONE]
46 ; CHECK: [P, N] -> { Stmt_store[i0] -> MemRef_a[i0] };