1 ; RUN: llc < %s -mcpu=cortex-a15 -verify-machineinstrs -arm-atomic-cfg-tidy=0 | FileCheck %s
3 ; Check a spill right after a function call with large struct byval is correctly
7 ; We expect 4-byte spill and reload to be generated.
9 ; CHECK-LABEL: set_stored_macroblock_parameters:
10 ; CHECK: str r0, [sp, #{{[0-9]}}] @ 4-byte Spill
12 ; CHECK: bl RestoreMVBlock8x8
13 ; CHECK: ldr r0, [sp, #{{[0-9]}}] @ 4-byte Reload
15 target triple = "armv7l-unknown-linux-gnueabihf"
17 %structN = type { i32, [16 x [16 x i32]], [16 x [16 x i32]], [16 x [16 x i32]], [3 x [16 x [16 x i32]]], [4 x i16], [4 x i8], [4 x i8], [4 x i8], [16 x [16 x i16]], [16 x [16 x i16]], [16 x [16 x i32]] }
19 @tr8x8 = external global %structN, align 4
20 @luma_transform_size_8x8_flag = external global i32, align 4
22 ; Function Attrs: nounwind
23 define void @set_stored_macroblock_parameters(i16 %a0, i32 %a1) #1 {
25 %0 = load i32, ptr @luma_transform_size_8x8_flag, align 4
26 tail call void asm sideeffect "", "~{r1},~{r2},~{r3},~{r4},~{r5},~{r6},~{r7},~{r8},~{r9},~{r10},~{r11}"()
27 tail call void @RestoreMVBlock8x8(i32 1, i32 2, ptr byval(%structN) @tr8x8, i32 0)
28 %arrayidx313 = getelementptr inbounds ptr, ptr null, i32 %0
29 %1 = load ptr, ptr %arrayidx313, align 4
30 store i8 -1, ptr %1, align 1
34 ; Function Attrs: nounwind
35 declare void @RestoreMVBlock8x8(i32, i32, ptr byval(%structN) nocapture, i32) #1
37 attributes #1 = { nounwind "less-precise-fpmad"="false" "frame-pointer"="none" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "unsafe-fp-math"="false" "use-soft-float"="false" }