Arnold Schwaighofer | 9779494 | 2007-11-10 10:48:01 +0000 | [diff] [blame] | 1 | ; RUN: llvm-as < %s | llc -march=x86 -tailcallopt | grep TAILCALL |
2 | %struct.s = type { i32, i32, i32 } | ||||
3 | |||||
4 | define fastcc i32 @tailcallee(%struct.s* byval %a) { | ||||
5 | entry: | ||||
6 | %tmp2 = getelementptr %struct.s* %a, i32 0, i32 0 | ||||
7 | %tmp3 = load i32* %tmp2 | ||||
8 | ret i32 %tmp3 | ||||
9 | } | ||||
10 | |||||
11 | define fastcc i32 @tailcaller(%struct.s* byval %a) { | ||||
12 | entry: | ||||
13 | %tmp4 = tail call fastcc i32 @tailcallee(%struct.s* %a byval) | ||||
14 | ret i32 %tmp4 | ||||
15 | } |