llvm-for-llvmta/test/Transforms/MergeFunc/tailcall.ll

22 lines
407 B
LLVM
Raw Normal View History

2022-04-25 10:02:23 +02:00
; RUN: opt -mergefunc -S < %s | FileCheck %s
declare void @dummy()
; CHECK-LABEL: define{{.*}}@foo
; CHECK: call {{.*}}@dummy
; CHECK: musttail {{.*}}@dummy
define void @foo() {
call void @dummy()
musttail call void @dummy()
ret void
}
; CHECK-LABEL: define{{.*}}@bar
; CHECK: call {{.*}}@dummy
; CHECK: call {{.*}}@dummy
define void @bar() {
call void @dummy()
call void @dummy()
ret void
}