1; RUN: opt %loadPolly -polly-scops -analyze < %s | FileCheck %s 2 3target 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" 4 5define void @f(i64* %a, i64 %N) { 6entry: 7 br label %for 8 9for: 10 %indvar = phi i64 [ 0, %entry ], [ %indvar.next, %for.backedge ] 11 br label %S1 12 13S1: 14 %scevgep1 = getelementptr i64, i64* %a, i64 %indvar 15 %val = load i64, i64* %scevgep1, align 8 16 br label %S2 17 18S2: 19 %scevgep2 = getelementptr i64, i64* %a, i64 %indvar 20 store i64 %val, i64* %scevgep2, align 8 21 br label %for.backedge 22 23for.backedge: 24 %indvar.next = add nsw i64 %indvar, 1 25 %exitcond = icmp eq i64 %indvar.next, %N 26 br i1 %exitcond, label %return, label %for 27 28return: 29 ret void 30} 31 32 33; CHECK: Arrays { 34; CHECK-NEXT: i64 MemRef_a[*]; // Element size 8 35; CHECK-NEXT: i64 MemRef_val; // Element size 8 36; CHECK-NEXT: } 37; 38; CHECK: Arrays (Bounds as pw_affs) { 39; CHECK-NEXT: i64 MemRef_a[*]; // Element size 8 40; CHECK-NEXT: i64 MemRef_val; // Element size 8 41; CHECK-NEXT: } 42; 43; CHECK: Statements { 44; CHECK-NEXT: Stmt_S1 45; CHECK-NEXT: Domain := 46; CHECK-NEXT: [N] -> { Stmt_S1[i0] : 0 <= i0 < N }; 47; CHECK-NEXT: Schedule := 48; CHECK-NEXT: [N] -> { Stmt_S1[i0] -> [i0, 0] }; 49; CHECK-NEXT: ReadAccess := [Reduction Type: NONE] [Scalar: 0] 50; CHECK-NEXT: [N] -> { Stmt_S1[i0] -> MemRef_a[i0] }; 51; CHECK-NEXT: MustWriteAccess := [Reduction Type: NONE] [Scalar: 1] 52; CHECK-NEXT: [N] -> { Stmt_S1[i0] -> MemRef_val[] }; 53; CHECK-NEXT: Stmt_S2 54; CHECK-NEXT: Domain := 55; CHECK-NEXT: [N] -> { Stmt_S2[i0] : 0 <= i0 < N }; 56; CHECK-NEXT: Schedule := 57; CHECK-NEXT: [N] -> { Stmt_S2[i0] -> [i0, 1] }; 58; CHECK-NEXT: MustWriteAccess := [Reduction Type: NONE] [Scalar: 0] 59; CHECK-NEXT: [N] -> { Stmt_S2[i0] -> MemRef_a[i0] }; 60; CHECK-NEXT: ReadAccess := [Reduction Type: NONE] [Scalar: 1] 61; CHECK-NEXT: [N] -> { Stmt_S2[i0] -> MemRef_val[] }; 62; CHECK-NEXT: } 63