summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/X86/tailcall-structret.ll
diff options
context:
space:
mode:
authorArnold Schwaighofer <arnold.schwaighofer@gmail.com>2009-03-28 08:33:27 +0000
committerArnold Schwaighofer <arnold.schwaighofer@gmail.com>2009-03-28 08:33:27 +0000
commit83d5420d028f36fc053ab48441b1dbabd1d54abe (patch)
treea03a0971095474d6ce25942793f5f0d563b93a47 /llvm/test/CodeGen/X86/tailcall-structret.ll
parent8372efd39ae411b16ae6051ba89bb9e62fd57a09 (diff)
downloadbcm5719-llvm-83d5420d028f36fc053ab48441b1dbabd1d54abe.tar.gz
bcm5719-llvm-83d5420d028f36fc053ab48441b1dbabd1d54abe.zip
Enable tail call optimization for functions that return a struct (bug 3664) and for functions that return types that need extending (e.g i1).
llvm-svn: 67934
Diffstat (limited to 'llvm/test/CodeGen/X86/tailcall-structret.ll')
-rw-r--r--llvm/test/CodeGen/X86/tailcall-structret.ll6
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/X86/tailcall-structret.ll b/llvm/test/CodeGen/X86/tailcall-structret.ll
new file mode 100644
index 00000000000..e94d7d8befa
--- /dev/null
+++ b/llvm/test/CodeGen/X86/tailcall-structret.ll
@@ -0,0 +1,6 @@
+; RUN: llvm-as < %s | llc -march=x86 -tailcallopt | grep TAILCALL
+define fastcc { { i8*, i8* }*, i8*} @init({ { i8*, i8* }*, i8*}, i32) {
+entry:
+ %2 = tail call fastcc { { i8*, i8* }*, i8* } @init({ { i8*, i8*}*, i8*} %0, i32 %1)
+ ret { { i8*, i8* }*, i8*} %2
+}
OpenPOWER on IntegriCloud