1 ; RUN: llc -mtriple=x86_64-linux-gnu %s -o - | FileCheck %s
3 declare swifttailcc void @callee([6 x i64], i64, i64)
5 @var = external global ptr
7 define swifttailcc void @caller(i64 %n) {
9 ; CHECK: subq $16, %rsp
11 ; CHECK: movq %rsp, %rbp
13 ; CHECK: andq $-32, %rsp
14 ; [... don't really care what happens to rsp to allocate %ptr ...]
15 ; CHECK: movq 24(%rbp), [[RETADDR:%.*]]
16 ; CHECK: movq [[RETADDR]], 8(%rbp)
17 ; CHECK: movq $42, 16(%rbp)
18 ; CHECK: movq $0, 24(%rbp)
19 ; CHECK: leaq -8(%rbp), %rsp
24 call void asm sideeffect "", "~{rbx}"()
25 %ptr = alloca i8, i64 %n, align 32
26 store ptr %ptr, ptr @var
27 tail call swifttailcc void @callee([6 x i64] undef, i64 42, i64 0)