36 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_test_checks.py2; RUN: opt -passes=correlated-propagation -S -o - %s | FileCheck %s3 4; Testcase that checks that we don't end in a neverending recursion resulting in5; a segmentation fault. The checks below verify that nothing is changed.6 7declare dso_local ptr @f2(ptr readnone returned) local_unnamed_addr8 9define dso_local void @f3() local_unnamed_addr {10; CHECK-LABEL: @f3(11; CHECK-NEXT: entry:12; CHECK-NEXT: br label [[FOR_COND:%.*]]13; CHECK: for.end:14; CHECK-NEXT: [[CALL6:%.*]] = call ptr @f2(ptr [[CALL6]])15; CHECK-NEXT: br i1 false, label [[FOR_COND]], label [[FOR_COND3:%.*]]16; CHECK: for.cond:17; CHECK-NEXT: [[C_0:%.*]] = phi ptr [ undef, [[ENTRY:%.*]] ], [ [[CALL6]], [[FOR_END:%.*]] ]18; CHECK-NEXT: br label [[FOR_COND3]]19; CHECK: for.cond3:20; CHECK-NEXT: ret void21;22entry:23 br label %for.cond24 25for.end:26 %call6 = call ptr @f2(ptr %call6)27 br i1 false, label %for.cond, label %for.cond328 29for.cond:30 %c.0 = phi ptr [ undef, %entry ], [ %call6, %for.end ]31 br label %for.cond332 33for.cond3:34 ret void35}36