[Polly] Partially fix scoped alias metadata

This partially addresses the verifier failures caused by D110026.
In particular, it does not fix the "second level" alias metadata.
This commit is contained in:
Nikita Popov 2021-09-20 22:19:51 +02:00
parent 16b5f4502c
commit 53720f74e4
25 changed files with 81 additions and 83 deletions

View File

@ -304,7 +304,7 @@ void ScopAnnotator::annotate(Instruction *Inst) {
return;
}
Inst->setMetadata("alias.scope", AliasScope);
Inst->setMetadata("alias.scope", MDNode::get(SE->getContext(), AliasScope));
Inst->setMetadata("noalias", OtherAliasScopeList);
}

View File

@ -10,13 +10,13 @@
; Stmt_for_body_3(32 * c0 + 4 * c2 + c4, 32 * c1 + c3);
; CHECK: polly.stmt.for.body.3: ; preds = %polly.loop_header18
; CHECK: %_p_splat_one = load <1 x double>, <1 x double>* %_p_vec_p, align 8, !alias.scope !3, !noalias !5, !llvm.access.group !2
; CHECK: %_p_vec_full = load <4 x double>, <4 x double>* %vector_ptr, align 8, !alias.scope !6, !noalias !7, !llvm.access.group !2
; CHECK: %_p_splat_one = load <1 x double>, <1 x double>* %_p_vec_p, align 8, !alias.scope !3, !noalias !6, !llvm.access.group !2
; CHECK: %_p_vec_full = load <4 x double>, <4 x double>* %vector_ptr, align 8, !alias.scope !6, !noalias !3, !llvm.access.group !2
; CHECK: extractelement <4 x double> %addp_vec, i32 0
; CHECK: extractelement <4 x double> %addp_vec, i32 1
; CHECK: extractelement <4 x double> %addp_vec, i32 2
; CHECK: extractelement <4 x double> %addp_vec, i32 3
; CHECK: store <4 x double> %addp_vec, <4 x double>* {{.*}}, align 8, !alias.scope !6, !noalias !7, !llvm.access.group !2
; CHECK: store <4 x double> %addp_vec, <4 x double>* {{.*}}, align 8, !alias.scope !6, !noalias !3, !llvm.access.group !2
define void @kernel_gemm(i32 %ni, i32 %nj, i32 %nk, [1024 x double]* %C, [1024 x double]* %A) #0 {
entry:

View File

@ -41,4 +41,4 @@ for.end: ; preds = %for.cond
; CHECK: %polly.access.cast.A = bitcast [100 x i32] addrspace(5)* %A to i32 addrspace(5)*
; CHECK: %polly.access.A = getelementptr i32, i32 addrspace(5)* %polly.access.cast.A, i64 0
; CHECK: %tmp2_p_scalar_ = load i32, i32 addrspace(5)* %polly.access.A, align 4, !alias.scope !0, !noalias !2
; CHECK: %tmp2_p_scalar_ = load i32, i32 addrspace(5)* %polly.access.A, align 4, !alias.scope !0, !noalias !3

View File

@ -29,17 +29,19 @@
; CODEGEN: %polly.access.cast.E = bitcast [270336 x [200000 x double]]* %E to double*
; CODEGEN: %polly.access.mul.E = mul nsw i64 %polly.indvar33, 200000
; CODEGEN: %polly.access.add.E = add nsw i64 %polly.access.mul.E, %polly.indvar
; CODEGEN: {{%.*}} = load double, double* %polly.access.E, align 8, !alias.scope [[TAG0:![0-9]+]], !noalias [[TAG2:![0-9]+]]
; CODEGEN: store double {{%.*}}, double* %scevgep36, align 8, !alias.scope [[TAG5:![0-9]+]], !noalias [[TAG8:![0-9]+]]
; CODEGEN: {{%.*}} = load double, double* %polly.access.E, align 8, !alias.scope !0, !noalias !3
; CODEGEN: store double {{%.*}}, double* %scevgep36, align 8, !alias.scope !8, !noalias !9
;
; CODEGEN: [[TAG0]] = distinct !{[[TAG0]], [[TAG1:![0-9]+]], !"polly.alias.scope.E"}
; CODEGEN: [[TAG1]] = distinct !{[[TAG1]], !"polly.alias.scope.domain"}
; CODEGEN: [[TAG2]] = !{[[TAG3:![0-9]+]], [[TAG4:![0-9]+]], [[TAG5:![0-9]+]], [[TAG6:![0-9]+]]}
; CODEGEN: [[TAG3]] = distinct !{[[TAG3]], [[TAG1]], !"polly.alias.scope.MemRef_B"}
; CODEGEN: [[TAG4]] = distinct !{[[TAG4]], [[TAG1]], !"polly.alias.scope.MemRef_A"}
; CODEGEN: [[TAG5]] = distinct !{[[TAG5]], [[TAG1]], !"polly.alias.scope.D"}
; CODEGEN: [[TAG6]] = distinct !{[[TAG6]], [[TAG1]], !"polly.alias.scope.F"}
; CODEGEN: [[TAG7:![0-9]+]] = !{[[TAG3]], [[TAG5]], [[TAG0]], [[TAG6]]}
; CODEGEN: !0 = !{!1}
; CODEGEN: !1 = distinct !{!1, !2, !"polly.alias.scope.E"}
; CODEGEN: !2 = distinct !{!2, !"polly.alias.scope.domain"}
; CODEGEN: !3 = !{!4, !5, !6, !7}
; CODEGEN: !4 = distinct !{!4, !2, !"polly.alias.scope.MemRef_B"}
; CODEGEN: !5 = distinct !{!5, !2, !"polly.alias.scope.MemRef_A"}
; CODEGEN: !6 = distinct !{!6, !2, !"polly.alias.scope.D"}
; CODEGEN: !7 = distinct !{!7, !2, !"polly.alias.scope.F"}
; CODEGEN: !8 = !{!5}
; CODEGEN: !9 = !{!4, !6, !1, !7}
;
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-unknown"

View File

@ -14,7 +14,7 @@
; CHECK: %[[R2:[._0-9]*]] = add nsw i64 %[[R1]], 99
; CHECK: %polly.access.A15 = getelementptr i32, i32* %polly.access.cast.A14, i64 %[[R2]]
; CHECK: %[[R3:[._0-9]*]] = bitcast i32* %polly.access.A15 to float*
; CHECK: %tmp14_p_scalar_ = load float, float* %[[R3]], align 4, !alias.scope !3, !noalias !4
; CHECK: %tmp14_p_scalar_ = load float, float* %[[R3]], align 4, !alias.scope !3, !noalias !0
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"

View File

@ -12,9 +12,9 @@
; SCEV-NEXT: %0 = trunc i64 %polly.indvar to i2
; SCEV-NEXT: %1 = zext i2 %0 to i64
; SCEV-NEXT: %scevgep = getelementptr float, float* %A, i64 %1
; SCEV-NEXT: %tmp4_p_scalar_ = load float, float* %scevgep, align 4, !alias.scope !0, !noalias !2
; SCEV-NEXT: %tmp4_p_scalar_ = load float, float* %scevgep, align 4, !alias.scope !0, !noalias !3
; SCEV-NEXT: %p_tmp5 = fadd float %tmp4_p_scalar_, 1.000000e+01
; SCEV-NEXT: store float %p_tmp5, float* %scevgep, align 4, !alias.scope !0, !noalias !2
; SCEV-NEXT: store float %p_tmp5, float* %scevgep, align 4, !alias.scope !0, !noalias !3
; SCEV-NEXT: %polly.indvar_next = add nsw i64 %polly.indvar, 1
; SCEV-NEXT: %polly.loop_cond = icmp sle i64 %polly.indvar_next, 99
; SCEV-NEXT: br i1 %polly.loop_cond, label %polly.loop_header, label %polly.loop_exit
@ -22,11 +22,11 @@
; ASTEXPR: polly.stmt.bb2: ; preds = %polly.loop_header
; ASTEXPR-NEXT: %pexp.pdiv_r = urem i64 %polly.indvar, 4
; ASTEXPR-NEXT: %polly.access.A = getelementptr float, float* %A, i64 %pexp.pdiv_r
; ASTEXPR-NEXT: %tmp4_p_scalar_ = load float, float* %polly.access.A, align 4, !alias.scope !0, !noalias !2
; ASTEXPR-NEXT: %tmp4_p_scalar_ = load float, float* %polly.access.A, align 4, !alias.scope !0, !noalias !3
; ASTEXPR-NEXT: %p_tmp5 = fadd float %tmp4_p_scalar_, 1.000000e+01
; ASTEXPR-NEXT: %pexp.pdiv_r1 = urem i64 %polly.indvar, 4
; ASTEXPR-NEXT: %polly.access.A2 = getelementptr float, float* %A, i64 %pexp.pdiv_r1
; ASTEXPR-NEXT: store float %p_tmp5, float* %polly.access.A2, align 4, !alias.scope !0, !noalias !2
; ASTEXPR-NEXT: store float %p_tmp5, float* %polly.access.A2, align 4, !alias.scope !0, !noalias !3
; ASTEXPR-NEXT: %polly.indvar_next = add nsw i64 %polly.indvar, 1
; ASTEXPR-NEXT: %polly.loop_cond = icmp sle i64 %polly.indvar_next, 99
; ASTEXPR-NEXT: br i1 %polly.loop_cond, label %polly.loop_header, label %polly.loop_exit

View File

@ -32,8 +32,8 @@ bb5: ; preds = %bb4
%tmp7 = getelementptr inbounds float, float* %A, i64 %i.0
%tmp6 = load float, float* %tmp, align 4
store float %tmp6, float* %tmp7, align 4
; CHECK: %tmp6_p_scalar_ = load float, float* %scevgep, align 4, !alias.scope !0, !noalias !2
; CHECK: store float %tmp6_p_scalar_, float* %scevgep8, align 4, !alias.scope !3, !noalias !4
; CHECK: %tmp6_p_scalar_ = load float, float* %scevgep, align 4, !alias.scope !0, !noalias !3
; CHECK: store float %tmp6_p_scalar_, float* %scevgep8, align 4, !alias.scope !3, !noalias !0
br label %bb8
bb8: ; preds = %bb5

View File

@ -23,13 +23,13 @@
; IR: %6 = add nsw i64 %polly.indvar5, 13
; IR: %polly.access.add.polly.subfunc.arg.A = add nsw i64 %polly.access.mul.polly.subfunc.arg.A, %6
; IR: %polly.access.polly.subfunc.arg.A = getelementptr float, float* %polly.subfunc.arg.A, i64 %polly.access.add.polly.subfunc.arg.A
; IR: %tmp10_p_scalar_ = load float, float* %polly.access.polly.subfunc.arg.A, align 4, !alias.scope !0, !noalias !2, !llvm.access.group !3
; IR: %tmp10_p_scalar_ = load float, float* %polly.access.polly.subfunc.arg.A, align 4, !alias.scope !0, !noalias !3, !llvm.access.group !4
; IR: %polly.access.mul.polly.subfunc.arg.A8 = mul nsw i64 %polly.indvar, %polly.subfunc.arg.m
; IR: %7 = add nsw i64 %polly.indvar5, 43
; IR: %polly.access.add.polly.subfunc.arg.A9 = add nsw i64 %polly.access.mul.polly.subfunc.arg.A8, %7
; IR: %polly.access.polly.subfunc.arg.A10 = getelementptr float, float* %polly.subfunc.arg.A, i64 %polly.access.add.polly.subfunc.arg.A9
; IR: store float %p_tmp11, float* %polly.access.polly.subfunc.arg.A10, align 4, !alias.scope !0, !noalias !2, !llvm.access.group !3
; IR: store float %p_tmp11, float* %polly.access.polly.subfunc.arg.A10, align 4, !alias.scope !0, !noalias !3, !llvm.access.group !4
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
define void @new_multidim_access(i64 %n, i64 %m, float* %A) {

View File

@ -4,27 +4,22 @@
;
; SCOPES-LABEL: polly.stmt.for.body:
; SCOPES: %[[BIdx:[._a-zA-Z0-9]*]] = getelementptr{{.*}} i32* %B, i64 %polly.indvar
; SCOPES: load i32, i32* %[[BIdx]], align 4, !alias.scope ![[AliasScopeB:[0-9]*]], !noalias ![[NoAliasB:[0-9]*]]
; SCOPES: load i32, i32* %[[BIdx]], align 4, !alias.scope !0, !noalias !3
; SCOPES: %[[CIdx:[._a-zA-Z0-9]*]] = getelementptr{{.*}} float* %C, i64 %polly.indvar
; SCOPES: load float, float* %[[CIdx]], align 4, !alias.scope ![[AliasScopeC:[0-9]*]], !noalias ![[NoAliasC:[0-9]*]]
; SCOPES: load float, float* %[[CIdx]], align 4, !alias.scope !6, !noalias !7
; SCOPES: %[[AIdx:[._a-zA-Z0-9]*]] = getelementptr{{.*}} i32* %A, i64 %polly.indvar
; SCOPES: store i32 %{{[._a-zA-Z0-9]*}}, i32* %[[AIdx]], align 4, !alias.scope ![[AliasScopeA:[0-9]*]], !noalias ![[NoAliasA:[0-9]*]]
; SCOPES: store i32 %{{[._a-zA-Z0-9]*}}, i32* %[[AIdx]], align 4, !alias.scope !8, !noalias !9
;
; SCOPES: ![[AliasScopeB]] = distinct !{![[AliasScopeB]], !{{[0-9]*}}, !"polly.alias.scope.MemRef_B"}
; SCOPES: ![[NoAliasB]] = !{
; SCOPES-DAG: ![[AliasScopeA]]
; SCOPES-DAG: ![[AliasScopeC]]
; SCOPES: }
; SCOPES-DAG: ![[AliasScopeA]] = distinct !{![[AliasScopeA]], !{{[0-9]*}}, !"polly.alias.scope.MemRef_A"}
; SCOPES-DAG: ![[AliasScopeC]] = distinct !{![[AliasScopeC]], !{{[0-9]*}}, !"polly.alias.scope.MemRef_C"}
; SCOPES: ![[NoAliasC]] = !{
; SCOPES-DAG: ![[AliasScopeA]]
; SCOPES-DAG: ![[AliasScopeB]]
; SCOPES: }
; SCOPES: ![[NoAliasA]] = !{
; SCOPES-DAG: ![[AliasScopeB]]
; SCOPES-DAG: ![[AliasScopeC]]
; SCOPES: }
; SCOPES: !0 = !{!1}
; SCOPES: !1 = distinct !{!1, !2, !"polly.alias.scope.MemRef_B"}
; SCOPES: !2 = distinct !{!2, !"polly.alias.scope.domain"}
; SCOPES: !3 = !{!4, !5}
; SCOPES: !4 = distinct !{!4, !2, !"polly.alias.scope.MemRef_C"}
; SCOPES: !5 = distinct !{!5, !2, !"polly.alias.scope.MemRef_A"}
; SCOPES: !6 = !{!4}
; SCOPES: !7 = !{!1, !5}
; SCOPES: !8 = !{!5}
; SCOPES: !9 = !{!1, !4}
;
; void jd(int *A, int *B, float *C) {
; for (int i = 0; i < 1024; i++)

View File

@ -8,9 +8,9 @@
; CHECK: polly.stmt.if.then: ; preds = %polly.loop_header
; CHECK: %p_conv = sitofp i64 %polly.indvar to float
; CHECK: %scevgep = getelementptr float, float* %A, i64 %polly.indvar
; CHECK: %_p_scalar_ = load float, float* %scevgep, align 4, !alias.scope !0, !noalias !2, !llvm.access.group !3
; CHECK: %_p_scalar_ = load float, float* %scevgep, align 4, !alias.scope !0, !noalias !3, !llvm.access.group !4
; CHECK: %p_add = fadd float %p_conv, %_p_scalar_
; CHECK: store float %p_add, float* %scevgep, align 4, !alias.scope !0, !noalias !2, !llvm.access.group !3
; CHECK: store float %p_add, float* %scevgep, align 4, !alias.scope !0, !noalias !3, !llvm.access.group !4
define void @foo(float* %A, i64 %N) #0 {
entry:

View File

@ -4,13 +4,13 @@
; This test case checks whether Polly generates alias metadata in case of
; the ublas gemm kernel and polly-invariant-load-hoisting.
;
; CHECK: store float 4.200000e+01, float* %polly.access.A.load, align 4, !alias.scope !3, !noalias !4
; CHECK: store float 4.200000e+01, float* %polly.access.A.load, align 4, !alias.scope !3, !noalias !0
;
; CHECK: !0 = distinct !{!0, !1, !"polly.alias.scope.MemRef_A"}
; CHECK-NEXT: !1 = distinct !{!1, !"polly.alias.scope.domain"}
; CHECK-NEXT: !2 = !{!3}
; CHECK-NEXT: !3 = distinct !{!3, !1, !"polly.alias.scope.MemRef_ptrA"}
; CHECK-NEXT: !4 = !{!0}
; CHECK: !0 = !{!1}
; CHECK-NEXT: !1 = distinct !{!1, !2, !"polly.alias.scope.MemRef_A"}
; CHECK-NEXT: !2 = distinct !{!2, !"polly.alias.scope.domain"}
; CHECK-NEXT: !3 = !{!4}
; CHECK-NEXT: !4 = distinct !{!4, !2, !"polly.alias.scope.MemRef_ptrA"}
;
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

View File

@ -2,7 +2,7 @@
; RUN: -polly-ignore-parameter-bounds -S < %s | FileCheck %s
; CHECK: polly.preload.begin:
; CHECK-NEXT: %global.load = load i32, i32* @global, align 4, !alias.scope !0, !noalias !2
; CHECK-NEXT: %global.load = load i32, i32* @global, align 4, !alias.scope !0, !noalias !3
; CHECK-NEXT: store i32 %global.load, i32* %tmp24.preload.s2a
target datalayout = "e-p:64:64:64-S128-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f16:16:16-f32:32:32-f64:64:64-f128:128:128-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64"

View File

@ -4,7 +4,7 @@ target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
; CHECK: polly.stmt.bb3: ; preds = %polly.stmt.bb3.entry
; CHECK: %tmp6_p_scalar_ = load double, double* %arg1{{[0-9]*}}, align 8, !alias.scope !0, !noalias !2
; CHECK: %tmp6_p_scalar_ = load double, double* %arg1{{[0-9]*}}, align 8, !alias.scope !0, !noalias !3
; CHECK: %p_tmp7 = fadd double 1.000000e+00, %tmp6_p_scalar_
; CHECK: %p_tmp8 = fcmp olt double 1.400000e+01, %p_tmp7
; CHECK: br i1 %p_tmp8, label %polly.stmt.bb9, label %polly.stmt.bb10

View File

@ -12,17 +12,17 @@
;
; CHECK: polly.stmt.bb2:
; CHECK: %scevgep[[R0:[0-9]*]] = getelementptr float, float* %A, i64 %polly.indvar
; CHECK: %tmp3_p_scalar_ = load float, float* %scevgep[[R0]], align 4, !alias.scope !0, !noalias !2
; CHECK: %tmp3_p_scalar_ = load float, float* %scevgep[[R0]], align 4, !alias.scope !0, !noalias !3
; CHECK: %scevgep[[R2:[0-9]*]] = getelementptr float, float* %scevgep{{[0-9]*}}, i64 %polly.indvar
; CHECK: %tmp6_p_scalar_ = load float, float* %scevgep[[R2]], align 4, !alias.scope !0, !noalias !2
; CHECK: %tmp6_p_scalar_ = load float, float* %scevgep[[R2]], align 4, !alias.scope !0, !noalias !3
; CHECK: %p_tmp7 = fcmp oeq float %tmp3_p_scalar_, %tmp6_p_scalar_
; CHECK: br i1 %p_tmp7, label %polly.stmt.bb8, label %polly.stmt.bb12.[[R:[a-zA-Z_.0-9]*]]
; CHECK: polly.stmt.bb8:
; CHECK: %scevgep[[R3:[0-9]*]] = getelementptr float, float* %A, i64 %polly.indvar
; CHECK: %tmp10_p_scalar_ = load float, float* %scevgep[[R3]], align 4, !alias.scope !0, !noalias !2
; CHECK: %tmp10_p_scalar_ = load float, float* %scevgep[[R3]], align 4, !alias.scope !0, !noalias !3
; CHECK: %p_tmp11 = fadd float %tmp10_p_scalar_, 1.000000e+00
; CHECK: store float %p_tmp11, float* %scevgep[[R3]], align 4, !alias.scope !0, !noalias !2
; CHECK: store float %p_tmp11, float* %scevgep[[R3]], align 4, !alias.scope !0, !noalias !3
; CHECK: br label %polly.stmt.bb12.[[R]]
; CHECK: polly.stmt.bb12.[[R]]:
@ -30,9 +30,9 @@
; CHECK: polly.stmt.bb12:
; CHECK: %scevgep[[R4:[0-9]*]] = getelementptr float, float* %A, i64 %polly.indvar
; CHECK: %tmp10b_p_scalar_ = load float, float* %scevgep[[R4]], align 4, !alias.scope !0, !noalias !2
; CHECK: %tmp10b_p_scalar_ = load float, float* %scevgep[[R4]], align 4, !alias.scope !0, !noalias !3
; CHECK: %p_tmp11b = fadd float %tmp10b_p_scalar_, 1.000000e+00
; CHECK: store float %p_tmp11b, float* %scevgep[[R4]], align 4, !alias.scope !0, !noalias !2
; CHECK: store float %p_tmp11b, float* %scevgep[[R4]], align 4, !alias.scope !0, !noalias !3
; CHECK: %polly.indvar_next = add nsw i64 %polly.indvar, 1
; CHECK: %polly.loop_cond = icmp sle i64 %polly.indvar_next, 1023
; CHECK: br i1 %polly.loop_cond, label %polly.loop_header, label %polly.loop_exit

View File

@ -38,7 +38,7 @@ return:
; CHECK: polly.stmt.body.Stmt_body_Write0.partial:
; CHECK-NEXT: %polly.access.A = getelementptr double, double* %A, i64 0
; CHECK-NEXT: store double 4.200000e+01, double* %polly.access.A, align 8, !alias.scope !0, !noalias !2
; CHECK-NEXT: store double 4.200000e+01, double* %polly.access.A, align 8, !alias.scope !0, !noalias !3
; CHECK-NEXT: br label %polly.stmt.body.cont
; CHECK: polly.stmt.body.cont:

View File

@ -3,7 +3,7 @@
; CHECK: polly.stmt.if.then81: ; preds = %polly.stmt.if.end75
; CHECK-NEXT: %scevgep = getelementptr [2 x %S], [2 x %S]* %tmp, i64 0, i64 %.147
; CHECK-NEXT: %scevgep1 = bitcast %S* %scevgep to float*
; CHECK-NEXT: store float undef, float* %scevgep1, align 4, !alias.scope !0, !noalias !2
; CHECK-NEXT: store float undef, float* %scevgep1, align 4, !alias.scope !0, !noalias !3
; CHECK-NEXT: br label %polly.stmt.if.end87.region_exiting
target datalayout = "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128"

View File

@ -49,10 +49,10 @@ if.then.i.i1141.loopexit: ; preds = %cond.end
; CHECK-LABEL: polly.stmt.cond.false:
; CHECK: %polly.access..pn{{[0-9]*}} = getelementptr i32, i32* %.pn, i64 %polly.indvar
; CHECK: store i32 %cond.in.sroa.speculate.load.cond.false_p_scalar_, i32* %polly.access..pn{{[0-9]*}}, align 4, !alias.scope !0, !noalias !2
; CHECK: store i32 %cond.in.sroa.speculate.load.cond.false_p_scalar_, i32* %polly.access..pn{{[0-9]*}}, align 4, !alias.scope !0, !noalias !3
; CHECK: br label %polly.merge
; CHECK-LABEL: polly.stmt.cond.false{{[0-9]*}}:
; CHECK: %polly.access..pn{{[0-9]*}} = getelementptr i32, i32* %.pn, i64 0
; CHECK: store i32 %cond.in.sroa.speculate.load.cond.false_p_scalar_{{[0-9]*}}, i32* %polly.access..pn{{[0-9]*}}, align 4, !alias.scope !0, !noalias !2
; CHECK: store i32 %cond.in.sroa.speculate.load.cond.false_p_scalar_{{[0-9]*}}, i32* %polly.access..pn{{[0-9]*}}, align 4, !alias.scope !0, !noalias !3
; CHECK: br label %polly.stmt.cond.end{{[0-9]*}}

View File

@ -29,7 +29,7 @@
; CHECK-LABEL: polly.stmt.bb4:
; CHECK: %tmp.0.s2a.reload[[R3:[0-9]*]] = load float, float* %tmp.0.s2a
; CHECK: %tmp[[R5:[0-9]*]]_p_scalar_ = load float, float* %scevgep, align 4, !alias.scope !0, !noalias !2
; CHECK: %tmp[[R5:[0-9]*]]_p_scalar_ = load float, float* %scevgep, align 4, !alias.scope !0, !noalias !3
; CHECK: %p_tmp[[R4:[0-9]*]] = fadd float %tmp.0.s2a.reload[[R3]], %tmp[[R5]]_p_scalar_
; CHECK: store float %p_tmp[[R4]], float* %tmp.0.phiops

View File

@ -29,7 +29,7 @@
; CHECK-LABEL: polly.stmt.bb4:
; CHECK: %tmp.0.s2a.reload[[R3:[0-9]*]] = load float, float* %tmp.0.s2a
; CHECK: %tmp[[R5:[0-9]*]]_p_scalar_ = load float, float* %scevgep, align 4, !alias.scope !0, !noalias !2
; CHECK: %tmp[[R5:[0-9]*]]_p_scalar_ = load float, float* %scevgep, align 4, !alias.scope !0, !noalias !3
; CHECK: %p_tmp[[R4:[0-9]*]] = fadd float %tmp.0.s2a.reload[[R3]], %tmp[[R5]]_p_scalar_
; CHECK: store float %p_tmp[[R4]], float* %tmp.0.phiops

View File

@ -41,8 +41,9 @@ for.cond.cleanup.loopexit:
; CHECK-LABEL: @func(
; CHECK: polly.stmt.omp.inner.for.body.us.us.us.preheader:
; CHECK: load i32, i32* %scevgep, align 4, !alias.scope !0, !noalias !2
; CHECK: load i32, i32* %scevgep, align 4, !alias.scope !0, !noalias !3
; CHECK: !0 = distinct !{!0, !1, !"polly.alias.scope.MemRef_d"}
; CHECK: !1 = distinct !{!1, !"polly.alias.scope.domain"}
; CHECK: !2 = !{}
; CHECK: !0 = !{!1}
; CHECK: !1 = distinct !{!1, !2, !"polly.alias.scope.MemRef_d"}
; CHECK: !2 = distinct !{!2, !"polly.alias.scope.domain"}
; CHECK: !3 = !{}

View File

@ -59,6 +59,6 @@ bb:
; STRIPMINE-NOT: <4 x float>
; CHECK: %tmp_p_vec_full = load <4 x float>, <4 x float>* bitcast ([1024 x float]* @A to <4 x float>*), align 8, !alias.scope !0, !noalias !2
; CHECK: %tmp_p_vec_full = load <4 x float>, <4 x float>* bitcast ([1024 x float]* @A to <4 x float>*), align 8, !alias.scope !0, !noalias !3
; CHECK: %tmp4p_vec = fadd <4 x float> %tmp_p_vec_full, <float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00>
; CHECK: store <4 x float> %tmp4p_vec, <4 x float>* bitcast ([1024 x float]* @B to <4 x float>*)

View File

@ -1,7 +1,7 @@
; RUN: opt %loadPolly -polly-codegen -S < %s | FileCheck %s
;
; CHECK: store i32 %8, i32* %scevgep, align 4, !alias.scope !1, !noalias !3
; CHECK: store i32 %9, i32* %scevgep4, align 4, !alias.scope !4, !noalias !5
; CHECK: store i32 %8, i32* %scevgep, align 4, !alias.scope !1, !noalias !4
; CHECK: store i32 %9, i32* %scevgep4, align 4, !alias.scope !4, !noalias !1
;
; void func(int *A, int *B){
; for (int i = 0; i < 1024; i+=1) {

View File

@ -12,13 +12,13 @@
; This test case checks whether Polly generates second level alias metadata
; to distinguish the specific accesses in case of the ublas gemm kernel.
;
; CHECK: !11 = distinct !{!11, !0, !"second level alias metadata"}
; CHECK: !12 = distinct !{!12, !0, !"second level alias metadata"}
; CHECK: !13 = !{!3, !4, !5, !6, !11}
; CHECK: !14 = distinct !{!14, !0, !"second level alias metadata"}
; CHECK: !15 = !{!3, !4, !5, !6, !11, !12}
; CHECK: !16 = distinct !{!16, !0, !"second level alias metadata"}
; CHECK: !17 = !{!3, !4, !5, !6, !11, !12, !14}
; CHECK: !16 = distinct !{!16, !1, !"second level alias metadata"}
; CHECK: !17 = distinct !{!17, !1, !"second level alias metadata"}
; CHECK: !18 = !{!4, !5, !6, !7, !16}
; CHECK: !19 = distinct !{!19, !1, !"second level alias metadata"}
; CHECK: !20 = !{!4, !5, !6, !7, !16, !17}
; CHECK: !21 = distinct !{!21, !1, !"second level alias metadata"}
; CHECK: !22 = !{!4, !5, !6, !7, !16, !17, !19}
;
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-unknown"

View File

@ -24,10 +24,10 @@
; IR-NEXT: %p_add.ptr2 = getelementptr inbounds i64, i64* %p_tmp1, i64 1
; IR-NEXT: %p_tmp2 = ptrtoint i64* %p_add.ptr2 to i64
; IR-NEXT: %p_arrayidx = getelementptr inbounds i64, i64* %A, i64 %p_tmp2
; IR-NEXT: %tmp3_p_scalar_ = load i64, i64* %p_arrayidx, align 8, !alias.scope !0, !noalias !2
; IR-NEXT: %tmp4_p_scalar_ = load i64, i64* %scevgep, align 8, !alias.scope !0, !noalias !2
; IR-NEXT: %tmp3_p_scalar_ = load i64, i64* %p_arrayidx, align 8, !alias.scope !0, !noalias !3
; IR-NEXT: %tmp4_p_scalar_ = load i64, i64* %scevgep, align 8, !alias.scope !0, !noalias !3
; IR-NEXT: %p_add4 = add nsw i64 %tmp4_p_scalar_, %tmp3_p_scalar_
; IR-NEXT: store i64 %p_add4, i64* %scevgep, align 8, !alias.scope !0, !noalias !2
; IR-NEXT: store i64 %p_add4, i64* %scevgep, align 8, !alias.scope !0, !noalias !3
; IR-NEXT: %polly.indvar_next = add nsw i64 %polly.indvar, 1
; IR-NEXT: %polly.loop_cond = icmp sle i64 %polly.indvar_next, 99
; IR-NEXT: br i1 %polly.loop_cond, label %polly.loop_header, label %polly.loop_exit

View File

@ -24,9 +24,9 @@
; IR-NEXT: %ptr13 = ptrtoint i64* %ptr to i16
;
; IR: polly.stmt.for.body:
; IR-NEXT: %tmp4_p_scalar_ = load i64, i64* %scevgep, align 8, !alias.scope !3, !noalias !4
; IR-NEXT: %tmp4_p_scalar_ = load i64, i64* %scevgep, align 8, !alias.scope !3, !noalias !0
; IR-NEXT: %p_add4 = add nsw i64 %tmp4_p_scalar_, %polly.preload.tmp3.merge
; IR-NEXT: store i64 %p_add4, i64* %scevgep, align 8, !alias.scope !3, !noalias !4
; IR-NEXT: store i64 %p_add4, i64* %scevgep, align 8, !alias.scope !3, !noalias !0
; IR-NEXT: %polly.indvar_next = add nsw i64 %polly.indvar, 1
; IR-NEXT: %polly.loop_cond = icmp sle i64 %polly.indvar_next, 99
; IR-NEXT: br i1 %polly.loop_cond, label %polly.loop_header, label %polly.loop_exit