xref: /llvm-project/llvm/test/Bitcode/tailcall.ll (revision ad6d6e742316e4ddc0c2879b92c85398b0847e31)
15772b777SReid Kleckner; RUN: llvm-as < %s | llvm-dis | FileCheck %s
2c8eccd11SDuncan P. N. Exon Smith; RUN: verify-uselistorder < %s
35772b777SReid Kleckner
45772b777SReid Kleckner; Check that musttail and tail roundtrip.
55772b777SReid Kleckner
6*ad6d6e74SVedant Kumardeclare cc1023 void @t1_callee()
7*ad6d6e74SVedant Kumardefine cc1023 void @t1() {
8*ad6d6e74SVedant Kumar; CHECK: tail call cc1023 void @t1_callee()
9*ad6d6e74SVedant Kumar  tail call cc1023 void @t1_callee()
105772b777SReid Kleckner  ret void
115772b777SReid Kleckner}
125772b777SReid Kleckner
13*ad6d6e74SVedant Kumardeclare cc1023 void @t2_callee()
14*ad6d6e74SVedant Kumardefine cc1023 void @t2() {
15*ad6d6e74SVedant Kumar; CHECK: musttail call cc1023 void @t2_callee()
16*ad6d6e74SVedant Kumar  musttail call cc1023 void @t2_callee()
175772b777SReid Kleckner  ret void
185772b777SReid Kleckner}
19