Home | History | Annotate | Download | only in X86
      1 ; RUN: llc < %s -tailcallopt=false | FileCheck %s
      2 ; CHECK: movl 8(%esp), %eax 
      3 ; CHECK: movl 8(%esp), %eax 
      4 ; CHECK-NOT: movl 8(%esp), %eax 
      5 
      6 ; PR3122
      7 ; rdar://6400815
      8 
      9 ; byval requires a copy, even with fastcc.
     10 
     11 target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64-f80:128:128"
     12 target triple = "i386-apple-darwin9.5"
     13 	%struct.MVT = type { i32 }
     14 
     15 define fastcc i32 @bar() nounwind {
     16 	%V = alloca %struct.MVT
     17 	%a = getelementptr %struct.MVT, %struct.MVT* %V, i32 0, i32 0
     18 	store i32 1, i32* %a
     19 	call fastcc void @foo(%struct.MVT* byval %V) nounwind
     20 	%t = load i32, i32* %a
     21 	ret i32 %t
     22 }
     23 
     24 declare fastcc void @foo(%struct.MVT* byval)
     25