Saleem Abdulrasool | b720a6b | 2014-03-11 15:09:49 +0000 | [diff] [blame] | 1 | ; RUN: llc < %s | FileCheck %s |
Manman Ren | 7e48b25 | 2012-10-12 23:39:43 +0000 | [diff] [blame] | 2 | |
| 3 | ; tail call inside a function where byval argument is splitted between |
| 4 | ; registers and stack is currently unsupported. |
| 5 | ; XFAIL: * |
| 6 | |
Cameron Zwarich | 033026f | 2011-06-17 02:16:43 +0000 | [diff] [blame] | 7 | target datalayout = "e-p:32:32:32-i1:8:32-i8:8:32-i16:16:32-i32:32:32-i64:32:32-f32:32:32-f64:32:32-v64:32:64-v128:32:128-a0:0:32-n32" |
Saleem Abdulrasool | b720a6b | 2014-03-11 15:09:49 +0000 | [diff] [blame] | 8 | target triple = "thumbv7-apple-ios5.0" |
Cameron Zwarich | 033026f | 2011-06-17 02:16:43 +0000 | [diff] [blame] | 9 | |
| 10 | %struct.A = type <{ i16, i16, i32, i16, i16, i32, i16, [8 x %struct.B], [418 x i8], %struct.C }> |
| 11 | %struct.B = type <{ i32, i16, i16 }> |
| 12 | %struct.C = type { i16, i32, i16, i16 } |
| 13 | |
| 14 | ; CHECK: f |
| 15 | ; CHECK: push {r1, r2, r3} |
| 16 | ; CHECK: add sp, #12 |
| 17 | ; CHECK: b.w _puts |
| 18 | |
| 19 | define void @f(i8* %s, %struct.A* nocapture byval %a) nounwind optsize { |
| 20 | entry: |
| 21 | %puts = tail call i32 @puts(i8* %s) |
| 22 | ret void |
| 23 | } |
| 24 | |
| 25 | declare i32 @puts(i8* nocapture) nounwind |