Support lowering of empty aggregates.
[oota-llvm.git] / test / CodeGen / ARM / tail-call.ll
1 ; RUN: llc -mtriple armv7 -O0 -o - < %s | FileCheck %s -check-prefix CHECK-TAIL
2 ; RUN: llc -mtriple armv7 -O0 -disable-tail-calls -o - < %s \
3 ; RUN:   | FileCheck %s -check-prefix CHECK-NO-TAIL
4
5 declare i32 @callee(i32 %i)
6
7 define i32 @caller(i32 %i) {
8 entry:
9   %r = tail call i32 @callee(i32 %i)
10   ret i32 %r
11 }
12
13 ; CHECK-TAIL-LABEL: caller
14 ; CHECK-TAIL: b callee
15
16 ; CHECK-NO-TAIL-LABEL: caller
17 ; CHECK-NO-TAIL: push {lr}
18 ; CHECK-NO-TAIL: bl callee
19 ; CHECK-NO-TAIL: pop {lr}
20 ; CHECK-NO-TAIL: bx lr
21