62 lines · plain
1; RUN: opt %loadNPMPolly -polly-stmt-granularity=bb '-passes=polly-custom<scops>' -polly-print-scops -disable-output < %s 2>&1 | FileCheck %s -match-full-lines2; Derived from test-suite/MultiSource/Applications/sgefa/blas.c3;4; The exit value of %i.0320 in land.rhs is not computable.5; It is still synthesizable in %if.end13---%for.end170 because6; %i.0320 is fixed within the SCoP and therefore just another parameter.7;8target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"9 10define void @snrm2(i32 %n) local_unnamed_addr {11entry:12 br label %land.rhs13 14land.rhs: ; preds = %while.body, %entry15 %i.0320 = phi i32 [ 0, %entry ], [ %inc, %while.body ]16 br i1 undef, label %while.body, label %if.end1317 18while.body: ; preds = %land.rhs19 %inc = add nuw nsw i32 %i.0320, 120 br label %land.rhs21 22if.end13: ; preds = %land.rhs23 %i.4284 = add nsw i32 %i.0320, 124 %cmp131285 = icmp slt i32 %i.4284, %n25 br i1 %cmp131285, label %for.body133.lr.ph, label %for.end17026 27for.body133.lr.ph: ; preds = %if.end1328 br label %for.body13329 30for.body133: ; preds = %for.body133, %for.body133.lr.ph31 %i.4289 = phi i32 [ %i.4284, %for.body133.lr.ph ], [ %i.4, %for.body133 ]32 %xmax.2287 = phi float [ undef, %for.body133.lr.ph ], [ undef, %for.body133 ]33 %i.4 = add nsw i32 %i.4289, 134 %exitcond = icmp eq i32 %i.4, %n35 br i1 %exitcond, label %for.end170, label %for.body13336 37for.end170: ; preds = %for.body133, %if.end1338 ret void39}40 41 42; CHECK: Region: %if.end13---%for.end17043 44; CHECK: Statements {45; CHECK-NEXT: Stmt_for_body133_lr_ph46; CHECK-NEXT: Domain :=47; CHECK-NEXT: [p_0, n] -> { Stmt_for_body133_lr_ph[] : n >= 2 + p_0 };48; CHECK-NEXT: Schedule :=49; CHECK-NEXT: [p_0, n] -> { Stmt_for_body133_lr_ph[] -> [0, 0] };50; CHECK-NEXT: MustWriteAccess := [Reduction Type: NONE] [Scalar: 1]51; CHECK-NEXT: [p_0, n] -> { Stmt_for_body133_lr_ph[] -> MemRef_xmax_2287__phi[] };52; CHECK-NEXT: Stmt_for_body13353; CHECK-NEXT: Domain :=54; CHECK-NEXT: [p_0, n] -> { Stmt_for_body133[i0] : 0 <= i0 <= -2 - p_0 + n };55; CHECK-NEXT: Schedule :=56; CHECK-NEXT: [p_0, n] -> { Stmt_for_body133[i0] -> [1, i0] };57; CHECK-NEXT: MustWriteAccess := [Reduction Type: NONE] [Scalar: 1]58; CHECK-NEXT: [p_0, n] -> { Stmt_for_body133[i0] -> MemRef_xmax_2287__phi[] };59; CHECK-NEXT: ReadAccess := [Reduction Type: NONE] [Scalar: 1]60; CHECK-NEXT: [p_0, n] -> { Stmt_for_body133[i0] -> MemRef_xmax_2287__phi[] };61; CHECK-NEXT: }62