1 ; RUN: llc < %s -mtriple=x86_64-pc-linux | FileCheck %s
3 declare x86_64_win64cc void @win64_callee(i32)
4 declare void @sysv_callee(i32)
6 define void @sysv_caller(i32 %p1) {
8 tail call x86_64_win64cc void @win64_callee(i32 %p1)
12 ; CHECK-LABEL: sysv_caller:
13 ; CHECK: subq $40, %rsp
14 ; CHECK: callq win64_callee
15 ; CHECK: addq $40, %rsp
18 define x86_64_win64cc void @win64_caller(i32 %p1) {
20 tail call void @sysv_callee(i32 %p1)
24 ; CHECK-LABEL: win64_caller:
25 ; CHECK: callq sysv_callee
28 define void @sysv_matched(i32 %p1) {
29 tail call void @sysv_callee(i32 %p1)
33 ; CHECK-LABEL: sysv_matched:
34 ; CHECK: jmp sysv_callee # TAILCALL
36 define x86_64_win64cc void @win64_matched(i32 %p1) {
37 tail call x86_64_win64cc void @win64_callee(i32 %p1)
41 ; CHECK-LABEL: win64_matched:
42 ; CHECK: jmp win64_callee # TAILCALL