1 // RUN: %clang_cc1 -triple armebv7-arm-none-eabi -emit-llvm -w -o - %s | FileCheck %s
3 // this tests for AAPCS section 5.4:
4 // A Composite Type not larger than 4 bytes is returned in r0.
5 // The format is as if the result had been stored in memory at a
6 // word-aligned address and then loaded into r0 with an LDR instruction
8 extern union Us
{ short s
; } us
;
9 union Us
callee_us(void) { return us
; }
10 // CHECK-LABEL: callee_us()
15 void caller_us(void) {
17 // CHECK-LABEL: caller_us()
23 extern struct Ss
{ short s
; } ss
;
24 struct Ss
callee_ss(void) { return ss
; }
25 // CHECK-LABEL: callee_ss()
30 void caller_ss(void) {
32 // CHECK-LABEL: caller_ss()