51 lines · plain
1; RUN: opt %loadNPMPolly '-passes=polly-custom<simplify>' -polly-print-simplify -disable-output -aa-pipeline=basic-aa < %s | FileCheck %s -match-full-lines2;3; Do not remove dependencies of a phi node within a region statement (%phi).4;5define void @func(i32 %n, ptr noalias nonnull %A, double %alpha) {6entry:7 br label %for8 9for:10 %j = phi i32 [0, %entry], [%j.inc, %inc]11 %j.cmp = icmp slt i32 %j, %n12 br i1 %j.cmp, label %body, label %exit13 14 body:15 %val = fadd double 21.0, 21.016 br label %region_entry17 18 19 region_entry:20 %region.cmp = fcmp ueq double %alpha, 0.021 br i1 %region.cmp, label %region_true, label %region_exit22 23 region_true:24 br i1 true, label %region_verytrue, label %region_mostlytrue25 26 region_verytrue:27 br label %region_mostlytrue28 29 region_mostlytrue:30 %phi = phi double [%val, %region_true], [0.0, %region_verytrue]31 store double %phi, ptr %A32 br label %region_exit33 34 region_exit:35 br label %inc36 37 38inc:39 %j.inc = add nuw nsw i32 %j, 140 br label %for41 42exit:43 br label %return44 45return:46 ret void47}48 49 50; CHECK: SCoP could not be simplified51