42 lines · plain
1; RUN: opt %loadNPMPolly '-passes=polly<no-default-opts>' -S < %s2;3; The entry of this scop's simple region (entry.split => for.end) has an trivial4; PHI node. LCSSA may create such PHI nodes. This is a breakdown of this case in5; the function 'Laguerre_With_Deflation' of oggenc from LLVM's test-suite.6;7target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"8 9define void @test(i64 %n, ptr noalias nonnull %A, float %a) {10entry:11 br label %entry.split12 13; CHECK-LABEL: %polly.split_new_and_old14; CHECK-NEXT: store float %a, ptr %b.phiops15 16; CHECK-LABEL: polly.stmt.entry.split17; CHECK-NEXT: %b.phiops.reload = load float, ptr %b.phiops18 19entry.split:20 %b = phi float [ %a, %entry ]21 store float %b, ptr %A, align 422 %cmp2 = icmp slt i64 %n, 523 br i1 %cmp2, label %for.cond, label %for.end24 25for.cond: ; preds = %for.inc, %entry26 %i.0 = phi i64 [ 0, %entry.split ], [ %add, %for.inc ]27 %cmp = icmp slt i64 %i.0, %n28 br i1 %cmp, label %for.body, label %for.end29 30for.body: ; preds = %for.cond31 %arrayidx = getelementptr inbounds float, ptr %A, i64 %i.032 store float %a, ptr %arrayidx, align 433 br label %for.inc34 35for.inc: ; preds = %for.body36 %add = add nuw nsw i64 %i.0, 137 br label %for.cond38 39for.end: ; preds = %for.cond40 ret void41}42