1 ; RUN: llc < %s -stackrealign -stack-alignment=32 -mattr=+avx -mtriple=x86_64-apple-darwin10 | FileCheck %s
4 define void @f(i64 %sz) uwtable {
6 %a = alloca i32, align 32
7 store volatile i32 0, i32* %a, align 32
8 ; force to push r14 on stack
9 call void asm sideeffect "nop", "~{r14},~{dirflag},~{fpsr},~{flags}"() nounwind, !srcloc !0
14 ; CHECK: .cfi_offset %rbp, -16
15 ; CHECK: movq %rsp, %rbp
16 ; CHECK: .cfi_def_cfa_register %rbp
18 ; We first push register on stack, and then realign it, so that
19 ; .cfi_offset value is correct
21 ; CHECK: andq $-32, %rsp
22 ; CHECK: .cfi_offset %r14, -24
24 ; Restore %rsp from %rbp and subtract the total size of saved regsiters.
25 ; CHECK: leaq -8(%rbp), %rsp
27 ; Pop saved registers.