aboutsummaryrefslogtreecommitdiffstats
path: root/test/CodeGen/SPARC/2011-01-21-ByValArgs.ll
blob: 85c16e4684edd3876861984a6e1543423079fbe5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
;RUN: llc -march=sparc < %s | FileCheck %s

%struct.foo_t = type { i32, i32, i32 }

@s = internal unnamed_addr global %struct.foo_t { i32 10, i32 20, i32 30 }

define i32 @test() nounwind {
entry:
;CHECK:     test
;CHECK:     st
;CHECK:     st
;CHECK:     st
;CHECK:     bar
  %0 = tail call i32 @bar(%struct.foo_t* byval @s) nounwind
  ret i32 %0
}

declare i32 @bar(%struct.foo_t* byval)