1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc < %s -mtriple=sparc -disable-sparc-leaf-proc | FileCheck %s
4 define i32 @test(i32 %a, i8* %va) nounwind {
6 ; CHECK: ! %bb.0: ! %entry
7 ; CHECK-NEXT: save %sp, -96, %sp
8 ; CHECK-NEXT: add %i1, 8, %i0
9 ; CHECK-NEXT: st %i0, [%fp+-4]
10 ; CHECK-NEXT: ld [%i1+4], %i0
11 ; CHECK-NEXT: add %i1, 12, %i2
12 ; CHECK-NEXT: st %i2, [%fp+-4]
13 ; CHECK-NEXT: ld [%i1+8], %i1
15 ; CHECK-NEXT: restore %i1, %i0, %o0
17 %va.addr = alloca i8*, align 4
18 store i8* %va, i8** %va.addr, align 4
19 %0 = va_arg i8** %va.addr, i64
20 %conv1 = trunc i64 %0 to i32
21 %1 = va_arg i8** %va.addr, i32
22 %add3 = add nsw i32 %1, %conv1