1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -verify-machineinstrs < %s | FileCheck %s
4 target datalayout = "e-m:e-i64:64-n32:64-S128-v256:256:256-v512:512:512"
5 target triple = "powerpc64le-unknown-linux-gnu"
7 %struct = type { [4 x i32], [20 x i8] }
9 declare dso_local i32 @foo1(ptr byval(%struct) %var)
10 declare dso_local void @foo(ptr %var)
12 ; check that 36bytes byval parameter is passed all in registers.
14 define dso_local i32 @bar() {
16 ; CHECK: # %bb.0: # %entry
18 ; CHECK-NEXT: stdu 1, -80(1)
19 ; CHECK-NEXT: std 0, 96(1)
20 ; CHECK-NEXT: .cfi_def_cfa_offset 80
21 ; CHECK-NEXT: .cfi_offset lr, 16
22 ; CHECK-NEXT: addi 3, 1, 40
25 ; CHECK-NEXT: lwz 7, 72(1)
26 ; CHECK-NEXT: ld 6, 64(1)
27 ; CHECK-NEXT: ld 5, 56(1)
28 ; CHECK-NEXT: ld 4, 48(1)
29 ; CHECK-NEXT: ld 3, 40(1)
32 ; CHECK-NEXT: addi 1, 1, 80
33 ; CHECK-NEXT: ld 0, 16(1)
37 %x = alloca %struct, align 8
38 call void @foo(ptr %x)
39 %r = call i32 @foo1(ptr byval(%struct) %x)