Add accelerator code generation pass skeleton
[polly-mirror.git] / test / ScopInfo / aliasing_with_non_affine_access.ll
blobdb719219e214df847018d771a1738188afabdc77
1 ; RUN: opt %loadPolly -analyze -polly-scops < %s | FileCheck %s
2 ; RUN: opt %loadPolly -analyze -polly-scops -pass-remarks-analysis="polly-scops" 2>&1 < %s | FileCheck %s --check-prefix=REMARK
4 ; This test case has a non-affine access (the memset call) that aliases with
5 ; other accesses. Thus, we bail out.
7 ; CHECK-NOT: Statements
9 ; REMARK:        remark: <unknown>:0:0: SCoP begins here.
10 ; REMARK-NEXT:   remark: <unknown>:0:0: Possibly aliasing pointer, use restrict keyword.
11 ; REMARK-NEXT:   remark: <unknown>:0:0: Possibly aliasing pointer, use restrict keyword.
12 ; REMARK-NEXT:   remark: <unknown>:0:0: No-aliasing assumption: {  : 1 = 0 }
13 ; REMARK-NEXT:   remark: <unknown>:0:0: SCoP ends here but was dismissed.
15 ; ModuleID = 'bugpoint-reduced-simplified.bc'
16 target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
18 %struct.info = type { i32, %struct.ctr*, i32, %struct.ord*, %struct.ctr*, i32, i8*, i32, i32, double }
19 %struct.ctr = type { i32, i8, i8, i32 }
20 %struct.ord = type { i32, i8 }
22 ; Function Attrs: argmemonly nounwind
23 declare void @llvm.memset.p0i8.i64(i8* nocapture, i8, i64, i32, i1) #0
25 ; Function Attrs: nounwind uwtable
26 define void @bestVirtualIndex(%struct.info** %ppIdxInfo) {
27 entry:
28   %0 = load %struct.info*, %struct.info** %ppIdxInfo, align 8
29   br label %if.end125
31 if.end125:                                        ; preds = %entry
32   %1 = load %struct.ctr*, %struct.ctr** undef, align 8
33   br label %for.end143
35 for.end143:                                       ; preds = %if.end125
36   %2 = bitcast %struct.ctr* %1 to i8*
37   tail call void @llvm.memset.p0i8.i64(i8* %2, i8 0, i64 32, i32 4, i1 false)
38   %needToFreeIdxStr = getelementptr inbounds %struct.info, %struct.info* %0, i64 0, i32 7
39   %3 = load i32, i32* %needToFreeIdxStr, align 8
40   br i1 false, label %if.end149, label %if.then148
42 if.then148:                                       ; preds = %for.end143
43   br label %if.end149
45 if.end149:                                        ; preds = %if.then148, %for.end143
46   unreachable
49 attributes #0 = { argmemonly nounwind }