1 ; RUN: opt %loadPolly -polly-detect-unprofitable -polly-code-generator=isl -polly-ast -analyze < %s | FileCheck %s --check-prefix=NOAA
2 ; RUN: opt %loadPolly -polly-detect-unprofitable -polly-code-generator=isl -polly-ast -analyze -tbaa < %s | FileCheck %s --check-prefix=TBAA
4 ; void jd(int *Int0, int *Int1, float *Float0, float *Float1) {
5 ; for (int i = 0; i < 1024; i++) {
7 ; Float0[i] = Float1[i];
12 ; NOAA-DAG: &MemRef_Float0[1024] <= &MemRef_Int0[0] || &MemRef_Int0[1024] <= &MemRef_Float0[0]
13 ; NOAA-DAG: &MemRef_Float1[1024] <= &MemRef_Int0[0] || &MemRef_Int0[1024] <= &MemRef_Float1[0]
14 ; NOAA-DAG: &MemRef_Int1[1024] <= &MemRef_Int0[0] || &MemRef_Int0[1024] <= &MemRef_Int1[0]
15 ; NOAA-DAG: &MemRef_Float0[1024] <= &MemRef_Float1[0] || &MemRef_Float1[1024] <= &MemRef_Float0[0]
16 ; NOAA-DAG: &MemRef_Int1[1024] <= &MemRef_Float0[0] || &MemRef_Float0[1024] <= &MemRef_Int1[0]
20 ; TBAA-DAG: &MemRef_Int0[1024] <= &MemRef_Int1[0] || &MemRef_Int1[1024] <= &MemRef_Int0[0]
21 ; TBAA-DAG: &MemRef_Float1[1024] <= &MemRef_Float0[0] || &MemRef_Float0[1024] <= &MemRef_Float1[0]
24 target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
26 define void @jd(i32* nocapture %Int0, i32* nocapture readonly %Int1, float* nocapture %Float0, float* nocapture readonly %Float1) {
30 for.body: ; preds = %for.body, %entry
31 %indvars.iv = phi i64 [ 0, %entry ], [ %indvars.iv.next, %for.body ]
32 %arrayidx = getelementptr inbounds i32, i32* %Int1, i64 %indvars.iv
33 %tmp = load i32* %arrayidx, align 4, !tbaa !0
34 %arrayidx2 = getelementptr inbounds i32, i32* %Int0, i64 %indvars.iv
35 store i32 %tmp, i32* %arrayidx2, align 4, !tbaa !0
36 %arrayidx4 = getelementptr inbounds float, float* %Float1, i64 %indvars.iv
37 %tmp1 = load float* %arrayidx4, align 4, !tbaa !4
38 %arrayidx6 = getelementptr inbounds float, float* %Float0, i64 %indvars.iv
39 store float %tmp1, float* %arrayidx6, align 4, !tbaa !4
40 %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
41 %exitcond = icmp eq i64 %indvars.iv.next, 1024
42 br i1 %exitcond, label %for.end, label %for.body
44 for.end: ; preds = %for.body
49 !1 = !{!"int", !2, i64 0}
50 !2 = !{!"omnipotent char", !3, i64 0}
51 !3 = !{!"Simple C/C++ TBAA"}
53 !5 = !{!"float", !2, i64 0}