1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mtriple=x86_64 < %s | FileCheck %s
4 ; Check the prolog won't be sunk across the save of CSRs.
5 define void @reduce(i32, i32, i32, i32, i32, i32, ...) nounwind {
8 ; CHECK-NEXT: subq $56, %rsp
9 ; CHECK-NEXT: testb %al, %al
10 ; CHECK-NEXT: je .LBB0_4
11 ; CHECK-NEXT: # %bb.3:
12 ; CHECK-NEXT: movaps %xmm0, -{{[0-9]+}}(%rsp)
13 ; CHECK-NEXT: movaps %xmm1, -{{[0-9]+}}(%rsp)
14 ; CHECK-NEXT: movaps %xmm2, -{{[0-9]+}}(%rsp)
15 ; CHECK-NEXT: movaps %xmm3, -{{[0-9]+}}(%rsp)
16 ; CHECK-NEXT: movaps %xmm4, -{{[0-9]+}}(%rsp)
17 ; CHECK-NEXT: movaps %xmm5, (%rsp)
18 ; CHECK-NEXT: movaps %xmm6, {{[0-9]+}}(%rsp)
19 ; CHECK-NEXT: movaps %xmm7, {{[0-9]+}}(%rsp)
20 ; CHECK-NEXT: .LBB0_4:
21 ; CHECK-NEXT: xorl %eax, %eax
22 ; CHECK-NEXT: testb %al, %al
23 ; CHECK-NEXT: jne .LBB0_2
24 ; CHECK-NEXT: # %bb.1:
25 ; CHECK-NEXT: leaq -{{[0-9]+}}(%rsp), %rax
26 ; CHECK-NEXT: movq %rax, 16
27 ; CHECK-NEXT: leaq {{[0-9]+}}(%rsp), %rax
28 ; CHECK-NEXT: movq %rax, 8
29 ; CHECK-NEXT: movl $48, 4
30 ; CHECK-NEXT: movl $48, 0
31 ; CHECK-NEXT: .LBB0_2:
32 ; CHECK-NEXT: addq $56, %rsp
34 br i1 undef, label %8, label %7
37 call void @llvm.va_start(ptr null)
44 declare void @llvm.va_start(ptr)
45 declare void @llvm.va_end(ptr)