llvm-project/llvm/test/Other/loop-print-after-pass-invalidated.ll
annamthomas 46c2d93662
[StandardInstrumentation] Annotate loops with the function name (#90756)
When analyzing pass debug output it is helpful to have the function name
along with the loop name.
2024-05-03 14:13:59 -04:00

22 lines
729 B
LLVM

; RUN: opt < %s 2>&1 -disable-output \
; RUN: -passes='simple-loop-unswitch<nontrivial>' \
; RUN: -print-after=simple-loop-unswitch \
; RUN: | FileCheck %s
; CHECK: *** IR Dump After SimpleLoopUnswitchPass on loop %for.cond in function loop ***
; CHECK: *** IR Dump After SimpleLoopUnswitchPass on loop %for.cond.us in function loop ***
define void @loop(i1 %w) {
entry:
br label %for.cond
; Loop:
for.cond: ; preds = %for.inc, %entry
br i1 %w, label %for.inc, label %if.then
if.then: ; preds = %for.cond
br label %for.inc
for.inc: ; preds = %if.then, %for.cond
br label %for.cond
}