33 lines · plain
1; RUN: opt < %s -passes='default<O1>' -disable-output -debug-pass-manager=verbose 2>&1 | FileCheck %s2; RUN: opt < %s -passes='default<O2>' -disable-output -debug-pass-manager=verbose 2>&1 | FileCheck %s3 4; BDCE only runs once in the function simplification pipeline and nowhere else so we use that to check for reruns.5 6; CHECK: PassManager{{.*}}SCC{{.*}} on (f1)7; CHECK: Running pass: BDCEPass on f18; CHECK: PassManager{{.*}}SCC{{.*}} on (f2, f3)9; CHECK: Running pass: BDCEPass on f210; CHECK-NOT: BDCEPass11; CHECK: PassManager{{.*}}SCC{{.*}} on (f2)12; CHECK-NOT: Running pass: BDCEPass on f213; CHECK: PassManager{{.*}}SCC{{.*}} on (f3)14; CHECK: Running pass: BDCEPass on f315 16define void @f1(ptr %p) alwaysinline {17 call void %p()18 ret void19}20 21define void @f2() #0 {22 call void @f1(ptr @f2)23 call void @f3()24 ret void25}26 27define void @f3() #0 {28 call void @f2()29 ret void30}31 32attributes #0 = { nofree noreturn nosync nounwind readnone noinline }33