X-Git-Url: http://plrg.eecs.uci.edu/git/?a=blobdiff_plain;f=test%2FCodeGen%2FX86%2Ftailcallbyval.ll;h=8a0113a645a35d6cb920a840fca134102f93bf28;hb=e3c6222c76543408d07c8ca274f0c4eb07780dcd;hp=916be566a14a34ddea09588fb62531c47359418c;hpb=e4300e271afd663ada8b808c6d0c4878fb0256ef;p=oota-llvm.git diff --git a/test/CodeGen/X86/tailcallbyval.ll b/test/CodeGen/X86/tailcallbyval.ll index 916be566a14..8a0113a645a 100644 --- a/test/CodeGen/X86/tailcallbyval.ll +++ b/test/CodeGen/X86/tailcallbyval.ll @@ -1,18 +1,21 @@ -; RUN: llvm-as < %s | llc -march=x86 -tailcallopt | grep TAILCALL -; RUN: llvm-as < %s | llc -march=x86 -tailcallopt | grep {movl\[\[:space:\]\]*4(%esp), %eax} | count 1 +; RUN: llc < %s -mtriple=i686-unknown-linux -tailcallopt | FileCheck %s %struct.s = type {i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32 } define fastcc i32 @tailcallee(%struct.s* byval %a) nounwind { entry: - %tmp2 = getelementptr %struct.s* %a, i32 0, i32 0 - %tmp3 = load i32* %tmp2 + %tmp2 = getelementptr %struct.s, %struct.s* %a, i32 0, i32 0 + %tmp3 = load i32, i32* %tmp2 ret i32 %tmp3 +; CHECK: tailcallee +; CHECK: movl 4(%esp), %eax } define fastcc i32 @tailcaller(%struct.s* byval %a) nounwind { entry: - %tmp4 = tail call fastcc i32 @tailcallee(%struct.s* %a byval) + %tmp4 = tail call fastcc i32 @tailcallee(%struct.s* byval %a ) ret i32 %tmp4 +; CHECK: tailcaller +; CHECK: jmp tailcallee }